# CoinMarketCap Scraper (`muhammetakkurtt/coinmarketcap-scraper`) Actor

CoinMarketCap Scraper extracts key cryptocurrency data like market cap, price trends, and volume. Filter by DeFi, NFT, or gaming categories and platforms. View prices in various currencies and sort by metrics. Ideal for crypto investors seeking deep market insights and portfolio tracking.

- **URL**: https://apify.com/muhammetakkurtt/coinmarketcap-scraper.md
- **Developed by:** [Muhammet Akkurt](https://apify.com/muhammetakkurtt) (community)
- **Categories:** Other, Developer tools, Automation
- **Stats:** 81 total users, 1 monthly users, 96.4% runs succeeded, 8 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $1.00 / 1,000 coin/token results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

![CoinMarketCap Scraper](https://i.postimg.cc/brKy09dk/coinmarketcap-logo.png)

## CoinMarketCap Scraper

This project is an Apify actor designed to scrape cryptocurrency information from CoinMarketCap. It collects details such as cryptocurrency name, symbol, market cap rank, and more based on the specified start and limit parameters.

### Features

- Fetches cryptocurrency data from CoinMarketCap according to specified start and limit parameters.
- Provides the ability to filter cryptocurrencies by category, algorithm, platform and industry.
- Collects detailed information (metadata, market data, audit information, etc.) for each cryptocurrency.
- Provides price display in different currencies (USD, EUR, ETH, BTC, etc.).
- It can sort according to various criteria (market capitalisation, trading volume, price change, etc.).
- Stores the collected data in the Apify data store.

### Usage

1. Run this actor in the Apify console.
2. Provide the desired inputs:
   - **start**: Starting position according to the specified characteristics
   - **limit**: How many cryptocurrencies to bring (default: 100)
   - **sortBy**: Sort criteria (market_cap, volume_24h, etc.)
   - **sortType**: Sort direction (asc or desc)
   - **convert**: The currency in which the prices will be displayed (USD, EUR, TRY, etc.)
   - **cryptoType**: Cryptocurrency type (all, coins, tokens)
   - **category**: Category filter (defi, gaming, privacy, etc.)
   - **algorithm**: Consensus algorithm (pos, pow, dpos, etc.)
   - **platform**: Blockchain platform (ethereum, binance-smart-chain, solana, etc.)
   - **industry**: Industry area (gaming, metaverse, artificial-intelligence, etc.)

#### Example Input

```json
{
  "start": 1,
  "limit": 100,
  "sortBy": "market_cap",
  "sortType": "desc",
  "convert": "USD",
  "cryptoType": "all",
  "category": "defi",
  "algorithm": "pos",
  "platform": "ethereum",
  "industry": "gaming"
}
```

### Output

The collected data is saved to the Apify dataset. The output data includes the following fields:

- `id`: Unique identifier of the cryptocurrency
- `logoUrl`: Logo URL of the cryptocurrency
- `name`: Name of the cryptocurrency
- `symbol`: Symbol of the cryptocurrency
- `cmcRank`: Market cap rank
- `marketPairCount`: Number of market pairs
- `circulatingSupply`: Circulating supply
- `selfReportedCirculatingSupply`: Self-reported circulating supply
- `totalSupply`: Total supply
- `ath`: All-time high price
- `atl`: All-time low price
- `high24h`: 24-hour high price
- `low24h`: 24-hour low price
- `isActive`: Whether the cryptocurrency is active
- `lastUpdated`: Last updated timestamp
- `dateAdded`: Date added to CoinMarketCap
- `price`: Current price in USD
- `volume24h`: 24-hour trading volume
- `volume7d`: 7-day trading volume
- `volume30d`: 30-day trading volume
- `marketCap`: Market capitalization
- `selfReportedMarketCap`: Self-reported market capitalization
- `percentChange1h`: 1-hour price change percentage
- `percentChange24h`: 24-hour price change percentage
- `percentChange7d`: 7-day price change percentage
- `percentChange30d`: 30-day price change percentage
- `percentChange60d`: 60-day price change percentage
- `percentChange90d`: 90-day price change percentage
- `fullyDilluttedMarketCap`: Fully diluted market capitalization
- `marketCapByTotalSupply`: Market cap by total supply
- `dominance`: Market dominance
- `turnover`: Turnover rate
- `ytdPriceChangePercentage`: Year-to-date price change percentage
- `percentChange1y`: 1-year price change percentage
- `usdQuoteLastUpdated`: Last updated timestamp for USD quote
- `isAudited`: Whether the cryptocurrency is audited
- `auditInfo`: Audit information, including:
  - `auditor`: Name of the auditor
  - `auditStatus`: Status of the audit
  - `score`: Audit score
  - `auditTime`: Time of the audit
  - `reportUrl`: URL to the audit report

### Example Output

```json
  {
    "id": 52,
    "logoUrl": "https://s2.coinmarketcap.com/static/img/coins/128x128/52.png",
    "name": "XRP",
    "symbol": "XRP",
    "cmcRank": 7,
    "marketPairCount": 1400,
    "circulatingSupply": 56564039920,
    "selfReportedCirculatingSupply": 0,
    "totalSupply": 99987161962,
    "maxSupply": 100000000000,
    "ath": 3.841939926147461,
    "atl": 0.002802350092679262,
    "high24h": 0.536341616635965,
    "low24h": 0.5268968405994953,
    "isActive": 1,
    "lastUpdated": "2024-10-05T19:41:00.000Z",
    "dateAdded": "2013-08-04T00:00:00.000Z",
    "price": 0.5330829865180338,
    "volume24h": 727310239.4412147,
    "volume7d": 6700700847.023869,
    "volume30d": 26597553702.163055,
    "marketCap": 30153327330.078884,
    "selfReportedMarketCap": 0,
    "percentChange1h": 0.21780229,
    "percentChange24h": -0.60403417,
    "percentChange7d": -14.35731985,
    "percentChange30d": -2.01017541,
    "percentChange60d": 3.26531819,
    "percentChange90d": 24.37414876,
    "fullyDilluttedMarketCap": 53308298651.8,
    "marketCapByTotalSupply": 53301454912.165306,
    "dominance": 1.4039,
    "turnover": 0.0241204,
    "ytdPriceChangePercentage": -15.3947,
    "percentChange1y": 2.22706974,
    "usdQuoteLastUpdated": "2024-10-05T19:41:00.000Z",
    "isAudited": true,
    "auditInfo": [
      {
        "auditor": "CertiK",
        "auditStatus": 2,
        "score": null,
        "auditTime": "2023-08-15T21:12:27.861Z",
        "reportUrl": "https://cmc.certik-skynet.com/redirect?project=xrp-ledger"
      }
    ]
  }
```

This example output shows the structured data of a single cryptocurrency. The actual output will be a list of similar objects for all processed cryptocurrencies.

### Notes

- The collected data is stored in Apify’s default data store.

# Actor input Schema

## `start` (type: `integer`):

Starting position in the cryptocurrency list (1 is the highest ranked)

## `limit` (type: `integer`):

Maximum number of cryptocurrencies to fetch

## `sortBy` (type: `string`):

Criteria by which cryptocurrencies will be sorted

## `sortType` (type: `string`):

Sort direction (ascending or descending)

## `convert` (type: `string`):

Currency in which prices will be displayed

## `cryptoType` (type: `string`):

Type of cryptocurrency to be listed

## `category` (type: `string`):

Category for filtering cryptocurrencies (if left blank, all will be included)

## `algorithm` (type: `string`):

Consensus algorithm for cryptocurrencies

## `platform` (type: `string`):

Blockchain platform on which the cryptocurrency is built

## `industry` (type: `string`):

Industry focus of the cryptocurrency project

## Actor input object example

```json
{
  "start": 1,
  "limit": 100,
  "sortBy": "market_cap",
  "sortType": "desc",
  "convert": "USD",
  "cryptoType": "all"
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("muhammetakkurtt/coinmarketcap-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("muhammetakkurtt/coinmarketcap-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call muhammetakkurtt/coinmarketcap-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,muhammetakkurtt/coinmarketcap-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/njaZhKIGQxSbPn4fP/builds/EVK3VxRGZdxyhD1h4/openapi.json
