Skip to main content
GET
/
v2
/
earn
/
aave_markets
Python (SDK)
from compass_api_sdk import CompassAPI


with CompassAPI(
    api_key_auth="<YOUR_API_KEY_HERE>",
) as compass_api:

    res = compass_api.earn.earn_aave_markets()

    # Handle response
    print(res)
{
  "markets": {
    "USDC": {
      "chains": {
        "base": {
          "address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
          "borrow_apy": "7.35",
          "supply_apy": "5.10"
        },
        "ethereum": {
          "address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
          "borrow_apy": "6.21",
          "supply_apy": "4.52"
        }
      },
      "max_supply_apy": {
        "address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
        "borrow_apy": "7.35",
        "chain": "base",
        "supply_apy": "5.10"
      }
    }
  }
}

Authorizations

x-api-key
string
header
required

Your Compass API Key. Get your key here.

Query Parameters

chain
enum<string> | null

Optional chain filter. If not provided, returns rates for all chains. The chain to use.

Available options:
base,
ethereum,
arbitrum

Response

Successful Response

Response containing Aave market rates organized by token symbol.

markets
Markets · object
required

Market data keyed by token symbol. Each token contains chain-specific data and information about which chain has the highest supply APY.

Example:
{
"USDC": {
"chains": {
"base": {
"address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
"borrow_apy": "7.35",
"supply_apy": "5.10"
},
"ethereum": {
"address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
"borrow_apy": "6.21",
"supply_apy": "4.52"
}
},
"max_supply_apy": {
"address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
"borrow_apy": "7.35",
"chain": "base",
"supply_apy": "5.10"
}
}
}