Get historical APY
Fetch APY history only.
https://api-v2.syncrone.fi/api/catalog/historical/{network}/{vaultId}/apyAPY per point, oldest first.
Try it#
Example#
A real response to the pre-filled Try it request, recorded from Syncrone data. Values move with every indexing run.
GET /historical/mainnet/0x98C23E9d8f34FEFb1B7BD6a91B7FF122F4e16F5c/apy?perPage=7&fromTimestamp=1790035200&toTimestamp=1790640000&granularity=1day&apyInterval=7day{
"itemsOnPage": 7,
"nextPage": 1,
"data": [
{
"timestamp": 1790035200,
"blockNumber": "26029315",
"apy": {
"base": 0.039627723811949345,
"reward": 0,
"total": 0.039627723811949345
}
},
{
"timestamp": 1790121600,
"blockNumber": "26036463",
"apy": {
"base": 0.04031720088026147,
"reward": 0,
"total": 0.04031720088026147
}
},
{
"timestamp": 1790208000,
"blockNumber": "26043610",
"apy": {
"base": 0.04055513451119497,
"reward": 0,
"total": 0.04055513451119497
}
},
{
"timestamp": 1790294400,
"blockNumber": "26050748",
"apy": {
"base": 0.04055261693289447,
"reward": 0,
"total": 0.04055261693289447
}
},
{
"timestamp": 1790380800,
"blockNumber": "26057904",
"apy": {
"base": 0.04056883230223729,
"reward": 0,
"total": 0.04056883230223729
}
},
{
"timestamp": 1790467200,
"blockNumber": "26065069",
"apy": {
"base": 0.04039966251598859,
"reward": 0,
"total": 0.04039966251598859
}
},
{
"timestamp": 1790553600,
"blockNumber": "26072221",
"apy": {
"base": 0.04023782817275712,
"reward": 0,
"total": 0.04023782817275712
}
}
]
}Parameters#
| Name | Type | Description |
|---|---|---|
| networkpathrequired | string | Network name ( |
| vaultIdpathrequired | string | Vault address (the share or receipt token, any case). A vault listed without an address is addressed by its |
| pagequery | integer | Page number, starting from 0. |
| perPagequery | integer | Items per page, 1 to 1000. |
| fromTimestampquery | integer | Start of the period, Unix seconds, inclusive. |
| toTimestampquery | integer | End of the period, Unix seconds, inclusive. Defaults to now. |
| granularityquery | string1day | 1week | Spacing of points. Vaults are indexed once a day at 00:00 UTC, so |
| apyIntervalquery | string1day | 7day | 30day | Trailing window of the APY at each point. Null until the vault has that much history. |
Response#
200 returns JSON with these fields. APY values are fractions (0.04 = 4%); timestamps are Unix seconds.
| Field | Type | Description |
|---|---|---|
| itemsOnPage | integer | Number of items in |
| nextPage | integer | Next page number. Absent on the last page. |
| data[].timestamp | integer | Point time, Unix seconds. |
| data[].blockNumber | string | null | Block the point was read at. |
| data[].apy | object | null | APY over the |
| data[].apy.base | number | TVL-weighted share-price APY, fraction. |
| data[].apy.reward | number | Mean reward APY over the window: on-chain emissions plus counted off-chain programs (Merkl). |
| data[].apy.total | number |
|
Errors#
| Status | Meaning |
|---|---|
| 400 | Invalid query or path parameter, or unknown network. |
| 401 | Missing or rejected API key. |
| 404 | No vault with this id on this network. |
| 429 | Too many requests from the docs playground. Wait a minute. |
| 500 | The service failed. |
Error bodies carry error and, for invalid parameters, details.