Problem
The AnalyticsModule has a pending TODO to fetch historical APY data from an off-chain indexer, which is necessary for the dashboard charts.
Expected behavior
A new asynchronous method getHistoricalAPY(timeframe: string) is added to AnalyticsModule that accepts standard timeframes (e.g., "7d", "30d") and returns an array of APY data points.
Files to update
src/modules/analytics.ts
docs/api-reference.md
Project relevance
This provides the data necessary for the yieldstream-dashboard to render the APY charts mentioned in the project overview.
Acceptance criteria
Problem
The
AnalyticsModulehas a pendingTODOto fetch historical APY data from an off-chain indexer, which is necessary for the dashboard charts.Expected behavior
A new asynchronous method
getHistoricalAPY(timeframe: string)is added toAnalyticsModulethat accepts standard timeframes (e.g., "7d", "30d") and returns an array of APY data points.Files to update
src/modules/analytics.tsdocs/api-reference.mdProject relevance
This provides the data necessary for the
yieldstream-dashboardto render the APY charts mentioned in the project overview.Acceptance criteria
{ timestamp: number, apy: string }