> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cryptoquant.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Retail Activity

> Retail activity through trading frequency surge — how far the daily number of trades is running above its own one-year average.

## What it measures

Retail activity through trading frequency surge — how far the daily number of trades is running above its own one-year average.

The daily number of trades (summed across all exchanges) is compared with its average over the trailing 12 months. That gap, in absolute terms and as a percentage of the one-year average, is smoothed with a 30-day and a 365-day moving average; the endpoint returns the difference between the two (MA30 − MA365, a MACD-style reading). A rising value means trading frequency is accelerating against its long-run level.

The source data is aggregated across exchanges: spot OHLCV and taker volume for `market=spot`, perpetual-contract OHLCV and taker volume for `market=futures`. Values are daily, recomputed every day at about 01:10 UTC over the full history; the latest row is the previous UTC day.

## Assets and windows

| Market | Assets | Windows |
| - | - | - |
| `spot` (default) | 448 assets, e.g. `btc`, `eth`, `sol`, `xrp`, `bnb`, `doge` | `day` |
| `futures` | 356 assets, e.g. `btc`, `eth`, `sol`, `xrp`, `bnb`, `doge` | `day` |

Pass `asset` as a lowercase symbol; several assets can be requested at once, comma-separated (`asset=btc,eth`). The supported assets differ between the two markets: an asset that is not supported for the requested market returns `400` (`Unsupported asset for spot: x`). The full lists are returned by [`/v2/discovery/endpoints`](https://docs.cryptoquant.com/v2/discovery). `window` accepts only `day`; any other value returns `400`. `limit` applies per asset.

Each call costs 20 credits.

## Response fields

Rows are returned under `result.data`, one per asset per day.

| Field | Type | Description |
| - | - | - |
| `date` | string | Day, `YYYY-MM-DD` (UTC). |
| `asset` | string | Asset symbol, lowercase. |
| `price_usd` | number | Price in USD: the median, across exchanges, of the daily close for USD-denominated quote currencies (USD, USDT, USDC, ...). |
| `gap_macd_absolute` | number | Trade-count gap (daily number of trades minus the trailing 12-month average) — 30-day moving average minus 365-day moving average. In number of trades. |
| `gap_macd_percentage` | number | Trade-count gap as a percentage of the trailing 12-month average — 30-day moving average minus 365-day moving average. In percentage points. The label is based on this value. |
| `macd_outlier_percentage` | string | Label derived from `gap_macd_percentage`. See the table below. |

## Labels

`macd_outlier_percentage` is a label. The label is assigned from `gap_macd_percentage`:

| Label | Condition |
| - | - |
| `Too Many Retail` | `gap_macd_percentage` ≥ 100 |
| `Many Retail` | 70 ≤ `gap_macd_percentage` \< 100 |
| `Few Retail` | 50 ≤ `gap_macd_percentage` \< 70 |
| `Neutral` | `gap_macd_percentage` \< 50 |


## OpenAPI

````yaml openapi/v2-top-indicator.json GET /indicator/top-indicator/retail-activity
openapi: 3.0.0
info:
  version: 2.0.0-beta
  title: CryptoQuant Data API v2 — Top Indicators
  description: >-
    Top Indicator endpoints of the CryptoQuant Data API v2 — daily market
    indicators (retail activity, average order size, volume bubble, taker CVD)
    for spot and futures markets, computed from exchange OHLCV and taker volume.
    Built on the v1 conventions: the `status`/`result` envelope, Bearer token
    authentication, and the `from`/`to` time parameters.
  termsOfService: https://cryptoquant.com/terms-of-service
  contact:
    name: API Support
    email: contact@cryptoquant.com
servers:
  - url: https://api.cryptoquant.com/v2
    description: Default server
security: []
tags:
  - name: Top Indicators
paths:
  /indicator/top-indicator/retail-activity:
    get:
      tags:
        - Top Indicators
      summary: Retail Activity
      description: >-
        Retail activity through trading frequency surge — how far the daily
        number of trades is running above its own one-year average.
      operationId: V2topIndicatorRetailActivity
      parameters:
        - name: asset
          in: query
          required: true
          description: >-
            Asset symbol, lowercase, e.g. `btc`. Comma-separated for several
            assets (e.g. `btc,eth`). 448 assets are available for `market=spot`
            and 356 for `market=futures`; an unsupported asset returns `400`.
          schema:
            type: string
          example: btc
        - name: market
          in: query
          required: false
          description: 'Market: `spot` (default) or `futures`.'
          schema:
            type: string
            enum:
              - spot
              - futures
            default: spot
        - name: window
          in: query
          required: false
          description: >-
            Aggregation window: `day` only (default). Any other value returns
            `400`.
          schema:
            type: string
            enum:
              - day
            default: day
          example: day
        - name: from
          in: query
          required: false
          description: Inclusive start date, `YYYYMMDD` (UTC).
          schema:
            type: string
        - name: to
          in: query
          required: false
          description: Inclusive end date, `YYYYMMDD` (UTC).
          schema:
            type: string
        - name: limit
          in: query
          required: false
          description: Maximum rows returned per asset (default 100, max 10000).
          schema:
            type: integer
            default: 100
            maximum: 10000
        - name: format
          in: query
          required: false
          description: 'Response format: `json` (default) or `csv`.'
          schema:
            type: string
            enum:
              - json
              - csv
            default: json
      responses:
        '200':
          description: Retail Activity daily time-series.
          content:
            application/json:
              schema:
                type: object
                required:
                  - status
                  - result
                properties:
                  status:
                    $ref: '#/components/schemas/Status'
                  result:
                    type: object
                    properties:
                      window:
                        type: string
                      data:
                        type: array
                        items:
                          type: object
                          properties:
                            date:
                              type: string
                              description: Day, `YYYY-MM-DD` (UTC).
                            asset:
                              type: string
                              description: Asset symbol, lowercase.
                            price_usd:
                              type: number
                              description: >-
                                Price in USD: the median, across exchanges, of
                                the daily close for USD-denominated quote
                                currencies (USD, USDT, USDC, ...).
                            gap_macd_absolute:
                              type: number
                              description: >-
                                Trade-count gap (daily number of trades minus
                                the trailing 12-month average) — 30-day moving
                                average minus 365-day moving average. In number
                                of trades.
                            gap_macd_percentage:
                              type: number
                              description: >-
                                Trade-count gap as a percentage of the trailing
                                12-month average — 30-day moving average minus
                                365-day moving average. In percentage points.
                                The label is based on this value.
                            macd_outlier_percentage:
                              type: string
                              description: >-
                                Label derived from `gap_macd_percentage`. See
                                the table below.
      security:
        - AccessToken: []
      x-codeSamples:
        - lang: Shell
          source: >-
            curl -X GET
            "https://api.cryptoquant.com/v2/indicator/top-indicator/retail-activity?asset=btc&window=day"
            \

            -H "Authorization: Bearer <YOUR_API_KEY>"
        - lang: JavaScript
          source: >-
            fetch("https://api.cryptoquant.com/v2/indicator/top-indicator/retail-activity?asset=btc&window=day",
            { headers: { "Authorization": "Bearer <YOUR_API_KEY>"} })
              .then(response => response.json())
              .then(data => console.log(data))
        - lang: NodeJS
          source: |-
            require('axios')
              .get("https://api.cryptoquant.com/v2/indicator/top-indicator/retail-activity?asset=btc&window=day", { headers: { Authorization: 'Bearer <YOUR_API_KEY>' } })
              .then(response => console.log(response))
        - lang: Ruby
          source: >-
            require 'net/http'

            uri =
            URI("https://api.cryptoquant.com/v2/indicator/top-indicator/retail-activity?asset=btc&window=day")

            req = Net::HTTP::Get.new(uri)

            req["Authorization"] = "Bearer <YOUR_API_KEY>"

            res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) {
            |http| http.request(req) }

            puts res.body
        - lang: Python
          source: >-
            import requests

            headers = {'Authorization': 'Bearer <YOUR_API_KEY>'}

            url =
            "https://api.cryptoquant.com/v2/indicator/top-indicator/retail-activity?asset=btc&window=day"

            print(requests.get(url, headers=headers).json())
components:
  schemas:
    Status:
      type: object
      description: >-
        Returned with every response; indicates whether the request was
        successful.
      required:
        - code
        - message
      properties:
        code:
          type: integer
          format: int32
          description: HTTP status code.
        message:
          type: string
          description: Text description of the error or success.
  securitySchemes:
    AccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        For each API request, include the `Authorization` HTTP header with
        `Bearer {access_token}`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.