Skip to main content

DeFi Lending Endpoints

Data sourced from DeFiLlama yields API, covering Aave, Compound, MakerDAO, Morpho, and more.

GET /v1/lending/rates

Returns all lending pools with supply/borrow APY.
curl "https://api.crypton.dev/v1/lending/rates"
{
  "status": "ok",
  "timestamp": 1709640000000,
  "data": {
    "pools": [
      {
        "protocol": "aave-v3",
        "chain": "ethereum",
        "asset": "USDC",
        "pool_id": "aave-v3-eth-usdc",
        "supply_apy": 3.52,
        "borrow_apy": 5.21,
        "tvl_usd": 2500000000.00,
        "utilization": 0.65,
        "reward_apy": null,
        "updated_at": 1709639900000
      }
    ],
    "total": 382
  }
}

Pool Fields

protocol
string
Lending protocol name.
chain
string
Blockchain network.
asset
string
Asset being lent/borrowed.
pool_id
string
Unique pool identifier.
supply_apy
number
Annual percentage yield for suppliers (%).
borrow_apy
number
Annual percentage rate for borrowers (%).
tvl_usd
number
Total value locked in USD.
utilization
number
Pool utilization ratio (0–1). Higher = more borrowed relative to supplied.
reward_apy
number | null
Additional reward token APY, if applicable.
updated_at
integer
Unix timestamp (ms).

GET /v1/lending/tvl

Returns TVL aggregated by protocol.
curl "https://api.crypton.dev/v1/lending/tvl"
{
  "status": "ok",
  "timestamp": 1709640000000,
  "data": {
    "protocols": [
      { "protocol": "aave-v3", "tvl_usd": 15000000000.00, "chains": ["ethereum", "polygon", "arbitrum"] }
    ],
    "total_tvl_usd": 45000000000.00
  }
}

GET /v1/lending/overview

Returns the best supply and borrow rates per asset across all protocols.
curl "https://api.crypton.dev/v1/lending/overview"
{
  "status": "ok",
  "timestamp": 1709640000000,
  "data": {
    "assets": [
      {
        "asset": "USDC",
        "best_supply": { "protocol": "morpho", "supply_apy": 5.2, "..." : "..." },
        "best_borrow": { "protocol": "aave-v3", "borrow_apy": 4.1, "..." : "..." },
        "avg_supply_apy": 3.8,
        "avg_borrow_apy": 5.5,
        "total_tvl": 8000000000.00
      }
    ]
  }
}

Field Reference

FieldTypeDescriptionGranularityExample
protocolstringLending protocol name (lowercase with version)Static"aave-v3"
chainstringBlockchain networkStatic"ethereum"
assetstringToken symbol being lent/borrowedStatic"USDC"
pool_idstringUnique pool identifier from DeFiLlamaStatic"aave-v3-eth-usdc"
supply_apynumberAnnual percentage yield for suppliers (%). Includes base + reward APY~5min via DeFiLlama3.52
borrow_apynumberAnnual percentage rate for borrowers (%)~5min via DeFiLlama5.21
tvl_usdnumberTotal value locked in this pool (USD)~5min2500000000.00
utilizationnumberBorrowed / Supplied ratio (0–1). Higher = more demand~5min0.65
reward_apynumber | nullAdditional reward token APY if applicable~5min1.2 or null

Data Sources

All lending data sourced from DeFiLlama Yields API, which aggregates on-chain data from Aave V2/V3, Compound V2/V3, MakerDAO/Spark, Morpho, and 200+ other protocols across Ethereum, Polygon, Arbitrum, Optimism, Base, BSC, and Avalanche. Data refreshes every ~5 minutes via DeFiLlama’s indexers.

Live Testing

# All lending pools
curl -s "https://api.crypton.dev/v1/lending/rates" | jq '.data.pools[:3]'

# TVL by protocol
curl -s "https://api.crypton.dev/v1/lending/tvl" | jq .

# Best rates per asset
curl -s "https://api.crypton.dev/v1/lending/overview" | jq '.data.assets[:3]'