Yearn Finance V2
Last updated
Last updated
Available on Ethereum, Arbitrum, Base and Optimism
Click on the endpoint to jump to the section with full details
GET
-Get balance of the user in a given Vault.
GET
- Get the number of the vaults along with the respective vault APY.
GET
- Trigger the deposit transaction for the given vault.
POST
- Trigger the withdraw transaction for the given vault.
Many endpoints have a parameter where you can provide a lendborrow ID.
Below is a list of lendborrow IDs related to Yearn Finance V2. Please see the for a complete Yield Aggregator ID list and more information.
Yearn Finance V2
Ethereum
5000
Yearn Finance V2
Arbitrum
5001
Yearn Finance V2
Base
5002
Yearn Finance V2
Optimism
5003
For /getbalance, the user can either pass the vaultAddress or the tokenAddress and the vaultNumber along with the required parameters.
GET
https://api.expand.network/yieldaggregator/getbalance
rpc
String
Remote procedural call URL.
address*
String
Public Address of the owner.
tokenAddress
String
The address of token.
vaultNumber
String
The number of the vault, incase there are multiple vaults.
yieldAggregatorId*
String
vaultAddress
String
The address of the vault.
GET
https://api.expand.network/yieldaggregator/getvaults
rpc
String
Remote procedural call URL
yieldAggregatorId*
String
tokenAddress
String
The address of token.
For /depositvault, the user can either pass the tokenAddress or the vaultAddress along with the required parameters.
POST
https://api.expand.network/yieldaggregator/depositvault
amount*
String
The amount of token to deposit.
tokenAddress
String
The address of the token.
from*
String
Address of the sender of the token.
gas*
String
Maximum gas limit provided by the sender, for the transaction.
vaultNumber
String
The number of the vault, in case there are multiple vaults.
vaultAddress
String
The address of the vault.
yieldAggregatorId*
String
gasPriority
String
low, medium, or high.
ofacCheck
Boolean
if true,
provides insights of the contract and tokens involved in the transaction.
By Default, false
Available on Ethereum, Polygon, BSC, Avalanche, Arbitrum and Optimism Mainnet
With ofacCheck:
For /withdrawvault, the user can either pass the tokenAddress or the vaultAddress along with the required parameters.
POST
https://api.expand.network/yieldaggregator/withdrawvault
amount*
String
Amount to be withdrawn.
from*
String
Address of the withdrawer of the token.
gas*
String
Maximum gas limit provided by the sender, for the transaction.
tokenAddress
String
Address of the token.
vaultNumber
String
The number of the vault, in case there are multiple vaults.
vaultAddress
String
Address of the vault.
yieldAggregatorId*
String
gasPriority
String
low, medium, or high.
ofacCheck
Boolean
if true,
provides insights of the contract and tokens involved in the transaction.
By Default, false
Available on Ethereum, Polygon, BSC, Avalanche, Arbitrum and Optimism Mainnet
With ofacCheck:
Refer to the page for details.
Refer to the page for details.
Refer to the page for details.
Refer to the page for details.