Lending History

Historical Lending Data

get
GetLendingHistory

https://data-api.defipulse.com/api/v1/defipulse/api/getLendingHistory
Returns historical data for a lending projects tracked on DeFi Pulse Lending over a given period of time.
Request
Response
Request
Query Parameters
api-key
required
string
Obtain an API-key by creating a free account at Data.defipulse.com
period
optional
string
Time period: 1w, 1m, 3m, 1y, or all. The 1w period will return hourly values all other periods will return daily values.
length
optional
string
Desired length of data set in hours or days can be used as an alternative to period for a more granular control over the returned data set
resolution
optional
string
Desired resolution: hours or history (=days), used together with length for a more granular control over the returned data set.
format
optional
string
Use csv to obtain data in CSV format
Response
200: OK
[{
"timestamp": "1586350800",
"lend_rates": {
"maker": 0,
"dydx": 1.6073438971911225,
"compound": 0.390075715838694,
"fulcrum": 1.0466441677664822
},
"borrow_rates": {
"maker": 1.6930161902874235,
"dydx": 3.7110249238156707,
"compound": 1.1497716453096796,
"fulcrum": 1.5262323876598989
},
"interest_speed": {
"total": {
"USD": 2356946.910336147,
"ETH": 13915.142935034522
},
"DAI": {
"USD": 2001216.7574024862,
"ETH": 11814.953107819614
},
"USDC": {
"USD": 239759.74773059099,
"ETH": 1415.5139197696953
},
"WETH": {
"USD": 107290.38608584988,
"ETH": 633.4300748957958
},
"BAT": {
"USD": 3320.834652050756,
"ETH": 19.605825080002102
},
"REP": {
"USD": 1438.7630814504664,
"ETH": 8.494291424314952
},
"WBTC": {
"USD": 3599.3590022196295,
"ETH": 21.25020074518615
},
"ZRX": {
"USD": 321.0623814994868,
"ETH": 1.8955152999143157
}
},
"outstanding": {
"total": {
"USD": 137033753.31566215,
"ETH": 809031.4872810378
},
"DAI": {
"USD": 123165644.4120839,
"ETH": 727155.7705283026
},
"USDC": {
"USD": 8070919.916452801,
"ETH": 47649.78106301099
},
"WETH": {
"USD": 5577379.426403696,
"ETH": 32928.2053749185
},
"BAT": {
"USD": 69069.1573181248,
"ETH": 407.77634501195416
},
"REP": {
"USD": 55521.6338459456,
"ETH": 327.79332770070613
},
"WBTC": {
"USD": 82433.66622712051,
"ETH": 486.6788654334662
},
"ZRX": {
"USD": 12785.103330582097,
"ETH": 75.48177665947631
}
}
}, ...
]

Additional Response Information:

Observe that the first entry in the array concerns the ongoing period (hour or day), while the following entries always concern a full period (hour or day) in the past, stepping back in time, starting from the period before the ongoing period. Timestamps are Unix epoch time.

Per timestamp, composite rates are given as lend_rates and borrow_rates. The endpoint also returns interest_speed and outstanding debt in total (USD and ETH), as well as for various individual tokens. See the graphs on this page to understand the values returned: https://defipulse.com/defi-lending.