Popcorn-Limited / vaultcraft

https://vaultcraft.vercel.app
4 stars 6 forks source link

Asset Resolver - Yearn #15

Closed RedVeil closed 1 year ago

RedVeil commented 1 year ago

We should fetch all assets that yearn supports. In order to do so we need to quite a few things: On the vaultRegistry:

  1. call numTokens to receive n
  2. increment the index until n is reached and call tokens with the current index.

On the vaultFactory:

  1. call allDeployedVaults
  2. loop over each vault and call token

Now we have the complete list of all supported tokens that we can return.

RedVeil commented 1 year ago

VaultRegistry: https://etherscan.io/address/0x50c1a2eA0a861A967D9d0FFE2AE4012c2E053804#readContract VaultFactory: https://etherscan.io/address/0x21b1fc8a52f179757bf555346130bf27c0c2a17a#readContract