# Layer-2 Tokens by 30-Day Performance - CoinGecko

**Use case:** 

Layer-2 scaling tokens ranked by 30-day price change, with 24h and 7-day change alongside it, price, market cap and volume. For sector-focused traders who want performance within one category rather than the whole market. Swap the category id for any other CoinGecko sector such as meme-token, artificial-intelligence or gaming.

## Input

```json
{
  "mode": "markets",
  "ids": [
    "bitcoin",
    "ethereum"
  ],
  "vsCurrency": "usd",
  "limit": 20,
  "category": "layer-2",
  "order": "market_cap_desc",
  "priceChangeWindows": [
    "24h",
    "7d",
    "30d"
  ],
  "includeSparkline": false,
  "sortBy": "change30d",
  "sortDir": "desc",
  "includeDescription": true,
  "includeTickers": false,
  "includeCommunity": false,
  "includeDeveloper": false,
  "includeNfts": false,
  "includeCategories": false,
  "categoryOrder": "market_cap_desc",
  "dailyOnly": true,
  "apiPlan": "demo"
}
```

## Output

```json
{
  "rank": {
    "label": "#",
    "format": "number"
  },
  "symbol": {
    "label": "Symbol",
    "format": "text"
  },
  "name": {
    "label": "Name",
    "format": "text"
  },
  "price": {
    "label": "Price",
    "format": "number"
  },
  "change1h": {
    "label": "1h %",
    "format": "number"
  },
  "change24h": {
    "label": "24h %",
    "format": "number"
  },
  "change7d": {
    "label": "7d %",
    "format": "number"
  },
  "marketCap": {
    "label": "Market cap",
    "format": "number"
  },
  "fdv": {
    "label": "FDV",
    "format": "number"
  },
  "volume24h": {
    "label": "Volume 24h",
    "format": "number"
  },
  "volumeToMcap": {
    "label": "Vol/MCap",
    "format": "number"
  },
  "circulatingSupply": {
    "label": "Circulating",
    "format": "number"
  },
  "athChangePct": {
    "label": "From ATH %",
    "format": "number"
  },
  "currency": {
    "label": "Ccy",
    "format": "text"
  },
  "id": {
    "label": "Id",
    "format": "text"
  },
  "sourceUrl": {
    "label": "Link",
    "format": "link"
  },
  "fetchedAt": {
    "label": "Fetched",
    "format": "date"
  }
}
```

## About this Actor

This example demonstrates how to use [CoinGecko Scraper — Crypto Prices, Market Cap, Volume, Trending](https://apify.com/yadroo/coingecko-markets.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/yadroo/coingecko-markets.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

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 full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/yadroo/coingecko-markets.md

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`).
