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

# Exchanges Historical

> Retrieves historical daily exchange metrics for the specified decentralized exchange.



## OpenAPI

````yaml get /metrics/exchanges/{exchange}/historical
openapi: 3.1.0
info:
  title: Defi Market API
  version: '2'
servers:
  - url: https://api.amberdata.com/market/defi
security:
  - sec0: []
paths:
  /metrics/exchanges/{exchange}/historical:
    get:
      summary: Exchanges Historical
      description: >-
        Retrieves historical daily exchange metrics for the specified
        decentralized exchange.
      operationId: defi-metrics-exchanges-historical
      parameters:
        - name: exchange
          in: path
          description: >-
            Exchange for which to return the global metrics - can be specified
            as:<BR/>- a name: `uniswapv2`<BR/>- an id:
            `0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f`
          schema:
            type: string
            default: uniswapv2
          required: true
        - name: startDate
          in: query
          description: >-
            **[Optional]** Payload only includes data after this date
            (inclusive).<BR/>**[Formats]** `seconds | milliseconds |
            iso8601`<BR/>**[Examples]** `1578531600 | 1578531600000 |
            2020-09-01T01:00:00`
          schema:
            type: string
            format: date-time
        - name: endDate
          in: query
          description: >-
            **[Optional]** Payload only includes data before this date
            (exclusive).<BR/>**[Formats]** `seconds | milliseconds |
            iso8601`<BR/>**[Examples]** `1578531600 | 1578531600000 |
            2020-09-01T01:00:00`
          schema:
            type: string
            format: date-time
        - name: timeFormat
          in: query
          description: >-
            **[Optional]** Time format of the timestamps in the return
            payload.<BR/>**[Defaults]** `milliseconds | ms* | iso | iso8601 | hr
            | human_readable`
          schema:
            type: string
      responses:
        '200':
          description: '200'
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                    example: 200
                  title:
                    type: string
                    example: OK
                  description:
                    type: string
                    example: Successful request
                  payload:
                    type: array
                    items:
                      type: object
                      properties:
                        exchangeId:
                          type: string
                          example: '0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f'
                        timestamp:
                          type: string
                          example: '2020-12-29T06:00:00.000Z'
                        liquidityTotalWETH:
                          type: string
                          example: '696597.309479738872001810'
                        liquidityTotalUSD:
                          type: string
                          example: '493048636.201664275395561830'
                        pairsTradedTotal:
                          type: integer
                          example: 52
                        pairsCumulativeTotal:
                          type: integer
                          example: 27293
                        tradesTotal:
                          type: integer
                          example: 85
      deprecated: false
components:
  securitySchemes:
    sec0:
      type: apiKey
      in: header
      x-default: API_KEY
      name: x-api-key

````