GET
/
metrics
/
exchanges
/
{exchange}
/
pairs
/
{pair}
/
historical
Pairs Historical
curl --request GET \
  --url https://api.amberdata.com/market/defi/metrics/exchanges/{exchange}/pairs/{pair}/historical \
  --header 'x-api-key: <api-key>'
{
  "status": 200,
  "title": "OK",
  "description": "Successful request",
  "payload": [
    {
      "exchangeId": "0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f",
      "timestamp": "2020-12-29T06:00:00.000Z",
      "address": "0x6b175474e89094c44da98b954eedeac495271d0f",
      "feesNative": "143.946130507571397825",
      "feesUSD": "144.013821392561330123",
      "liquidityTotalNative": "103973505.181589129290317518",
      "liquidityTotalUSD": "104022398.879227475227263226",
      "pairsTradedTotal": 1,
      "tradesTotal": 3445,
      "priceNative": "0.00075603290509702245",
      "volumeTotalNative": "47982.043502523799274881",
      "volumeTotalUSD": "48004.607130853776707797"
    }
  ]
}

Authorizations

x-api-key
string
header
default:API_KEY
required

Path Parameters

exchange
string
default:uniswapv2
required

Exchange for which to return the global metrics - can be specified as:<BR/>- a name: uniswapv2<BR/>- an id: 0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f

pair
string
default:0xa478c2975ab1ea89e8196811f51a7b7ade33eb11
required

Pair for which to return the metrics, for example:<BR/>- 0xa478c2975ab1ea89e8196811f51a7b7ade33eb11 (DAI_WETH)

Query Parameters

startDate
string<date-time>

[Optional] Payload only includes data after this date (inclusive).<BR>[Formats] seconds | milliseconds | iso8601<BR>[Examples] 1578531600 | 1578531600000 | 2020-09-01T00:00:00

endDate
string<date-time>

[Optional] Payload only includes data before this date (exclusive).<BR>[Formats] seconds | milliseconds | iso8601<BR>[Examples] 1578531600 | 1578531600000 | 2020-09-02T00:00:00

timeFormat
string

[Optional] Time format of the timestamps in the return payload.<BR/>[Defaults] milliseconds | ms* | iso | iso8601 | hr | human_readable

Response

200 - application/json

200

The response is of type object.