GET
/
stablecoins
/
{assetSymbol}
/
lending
/
metrics
/
summary
Stablecoins in DeFi Lending - Aggregate Insights
curl --request GET \
  --url https://api.amberdata.com/defi/stablecoins/{assetSymbol}/lending/metrics/summary \
  --header 'x-api-key: <api-key>'
{
  "status": 200,
  "title": "OK",
  "description": "Successful request",
  "payload": {
    "metadata": {
      "blockchainId": "avalanche-mainnet",
      "protocols": [
        "aavev2"
      ]
    },
    "data": {
      "metrics": [
        {
          "timestamp": 1685145599999,
          "depositedUSD": 12245600.841895984,
          "borrowedUSD": 111607.91129839412,
          "withdrawnUSD": 8063459.152456514,
          "repaidUSD": 214781.74953266996,
          "liquidatedUSD": 0,
          "liquidatedProfitUSD": 0,
          "flashLoanedUSD": 55544.3264730185,
          "interestEarnedUSD": 2590.714350187115,
          "interestPaidUSD": 287.8571500207906,
          "numberOfDeposits": 186,
          "numberOfBorrows": 37,
          "numberOfWithdraws": 191,
          "numberOfRepays": 26,
          "numberOfLiquidations": 0,
          "depositRatio": 0.8472260491461453,
          "borrowRatio": 0.01629069721658102,
          "withdrawRatio": 1.176971865549357,
          "liquidationRatio": 0,
          "totalDepositedUSD": 63039186.64521183,
          "totalCollateralUSD": 159364840.70693165,
          "totalBorrowedUSD": 39488498.24221587,
          "cumulativeLiquidatedUSD": 25058036.913995497,
          "cumulativeLiquidatedProfitUSD": 1130173.4298008725,
          "cumulativeInterestEarnedUSD": 28758573.133691713,
          "totalUtilizationRatio": 0.6264119247676753,
          "totalDepositConcentration": 0.18215099394158993,
          "totalBorrowConcentration": 0.37577326222343804
        }
      ]
    }
  }
}

Authorizations

x-api-key
string
header
default:API_KEY
required

Headers

x-amberdata-blockchain-id
enum<string>

[Optional] The id of the blockchain for which you want data from. Defaults to ethereum-mainnet if not specified.

Available options:
ethereum-mainnet,
avalanche-mainnet,
arbitrum-mainnet,
optimism-mainnet

Path Parameters

assetSymbol
enum<string>
default:USDC
required
Available options:
USDC,
USDT,
DAI,
BUSD,
TUSD

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-01T01:00:00

endDate
string<date-time>

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

timeInterval
enum<string>
default:days

Determines whether the metrics are aggregated by hour or by day.

Available options:
days,
hours
protocol
enum<string>

Drill down into the stablecoin's metrics by specifying a protocol.

Available options:
aavev2,
aavev3,
makerdao,
compoundv2,
compoundv3
timeFormat
enum<string>
default:hr

[Optional] Time format of the timestamps in the return payload.

Available options:
milliseconds,
ms,
iso,
iso8601,
hr,
human_readable

Response

200 - application/json

200

The response is of type object.