Skip to main content
Fetches the most recent APY data for an account from the backend API.

Import

Usage

Parameters

ParameterTypeRequiredDescription
vaultAddressAddressNoAccount contract address (required if vaultName omitted)
vaultNamestringNoAccount name — resolved to address via cache
chainIdnumberNoBlockchain network ID (optional filter)
Provide either vaultAddress or vaultName. When vaultName is provided, the SDK resolves the address from cache.

Return Type

Example: APY Display Component

Error Handling

Error Message PatternDescriptionResolution
"SDK not initialized"SDK not initializedCall initAmplifySDK() first
"No APY data found"No data for accountVerify account address
"Failed to fetch vault APY"Network or API errorCheck connection and retry