Function Signature
Description
Returns the rewards an owner has accrued in an Earn vault. Rewards are a separate bonus some vaults pay in another token, and they sit unclaimed until claimed, unlike base yield, which shows up asassets growing.
Available as client.earn on DynamicEvmWalletClient and DynamicSvmWalletClient.
Rewards are supported only for vaults from some providers. For a vault from any other
provider, the API rejects the request with an HTTP 400 error. See
Provider support.
Parameters
Required Parameters
vaultId(string): The vault identifier fromlistVaults.ownerAddress(string): The wallet address that accrued the rewards.
Optional Parameters
traceContext(TraceContext): Trace context forwarded to the Dynamic API.
Returns
Promise<EarnVaultReward[]>: The accrued rewards. Empty when the owner has accrued nothing. Amounts are raw-unit strings.