---
title: "Individual AMM fee collections."
method: GET
path: "/v1/analytics/markets/fees/amm"
tags: ["markets"]
---

# Individual AMM fee collections.

`GET /v1/analytics/markets/fees/amm`

One row per AMM fee collection, crvUSD 18dp. `debtRaw` is AMM debt after accrual, not a supply. Zero-amount collections are excluded. Newest first; `isDesc` and `sortBy=date|amount` change it. New rows only prepend, so dedupe on `id` while paging. `minAmountUsd` drops priced rows under the given threshold ($0.1, $1, $100, $1000, $10000, $100000, $1000000); `totalCount` follows it. A row with a real amount and no USD value is kept whatever the threshold — unpriced is not filtered, and ranks at zero. Omitting `marketIdx` spans every market. `offset` is capped at 1000000 and a request past it is a 400 — narrow with `marketIdx` or `minAmountUsd`.

## Query parameters

- `chainId` string
- `limit` string — Integer 1-200; outside is a 400, never clamped.
- `offset` string — Integer 0-1000000; outside is a 400, never clamped.
- `marketIdx` string — Integer 0-64; outside is a 400, never clamped.
- `includeLegacy` 'true' | 'false'
- `minAmountUsd` '0.1' | '1' | '100' | '1000' | '10000' | '100000' | '1000000'
- `isDesc` 'true' | 'false'
- `sortBy` 'date' | 'amount'

## Response `200`

Individual AMM fee collections.

- object
  - `success` true, required
  - `data` object[], required
    - `id` string, required
    - `marketId` string, required
    - `blockNumber` number, required
    - `blockTimestamp` number, required
    - `transactionHash` string, required
    - `logIndex` number, required
    - `ammAddress` string, required
    - `amountRaw` string, required
    - `amountUsdRaw` string, required
    - `debtRaw` string, required
  - `totalCount` string, required
  - `timestamp` string, required

## Other responses

- `400` — Invalid request
- `500` — Internal error
- `502` — Upstream data/schema error

---

[API](https://skmtc.dev/yieldbasis/apis/yieldbasis-api.md) · [All operations](https://skmtc.dev/yieldbasis/apis/yieldbasis-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/yieldbasis/yieldbasis-api/revisions/b5b24c7435c8/schema)
