@underscore-finance/sdk 1.2.17 → 1.2.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/AGENTS.md +161 -0
  2. package/README.md +17 -116
  3. package/abis.json +179426 -0
  4. package/addresses.json +75 -0
  5. package/dist/contracts/AaveV3.d.ts.map +1 -1
  6. package/dist/contracts/AaveV3.js +1898 -1919
  7. package/dist/contracts/AeroClassic.d.ts.map +1 -1
  8. package/dist/contracts/AeroClassic.js +1518 -1533
  9. package/dist/contracts/AeroSlipstream.d.ts.map +1 -1
  10. package/dist/contracts/AeroSlipstream.js +1620 -1641
  11. package/dist/contracts/AgentSenderGeneric.d.ts +1 -1
  12. package/dist/contracts/AgentSenderGeneric.d.ts.map +1 -1
  13. package/dist/contracts/AgentSenderGeneric.js +3093 -3108
  14. package/dist/contracts/AgentSenderSpecial.d.ts +1 -1
  15. package/dist/contracts/AgentSenderSpecial.d.ts.map +1 -1
  16. package/dist/contracts/AgentSenderSpecial.js +1495 -1510
  17. package/dist/contracts/AgentSenderSpecialSigHelper.d.ts +1 -1
  18. package/dist/contracts/AgentSenderSpecialSigHelper.d.ts.map +1 -1
  19. package/dist/contracts/AgentSenderSpecialSigHelper.js +1733 -1733
  20. package/dist/contracts/AgentWrapper.d.ts +1 -1
  21. package/dist/contracts/AgentWrapper.d.ts.map +1 -1
  22. package/dist/contracts/AgentWrapper.js +1926 -1929
  23. package/dist/contracts/AgentWrapperV1.d.ts +1 -1
  24. package/dist/contracts/AgentWrapperV1.d.ts.map +1 -1
  25. package/dist/contracts/AgentWrapperV1.js +2727 -2742
  26. package/dist/contracts/AgentWrapperV2.d.ts +1 -1
  27. package/dist/contracts/AgentWrapperV2.d.ts.map +1 -1
  28. package/dist/contracts/AgentWrapperV2.js +1832 -1835
  29. package/dist/contracts/Appraiser.d.ts.map +1 -1
  30. package/dist/contracts/Appraiser.js +404 -410
  31. package/dist/contracts/Avantis.d.ts.map +1 -1
  32. package/dist/contracts/Avantis.js +1905 -1929
  33. package/dist/contracts/Billing.d.ts.map +1 -1
  34. package/dist/contracts/Billing.js +235 -247
  35. package/dist/contracts/ChequeBook.d.ts.map +1 -1
  36. package/dist/contracts/ChequeBook.js +868 -877
  37. package/dist/contracts/CompoundV3.d.ts.map +1 -1
  38. package/dist/contracts/CompoundV3.js +1919 -1943
  39. package/dist/contracts/ConvertVaultToken.d.ts.map +1 -1
  40. package/dist/contracts/ConvertVaultToken.js +31 -31
  41. package/dist/contracts/Curve.d.ts.map +1 -1
  42. package/dist/contracts/Curve.js +787 -802
  43. package/dist/contracts/DefaultsBase.d.ts.map +1 -1
  44. package/dist/contracts/DefaultsBase.js +178 -178
  45. package/dist/contracts/ERC20.d.ts.map +1 -1
  46. package/dist/contracts/ERC20.js +186 -192
  47. package/dist/contracts/EarnVault.d.ts.map +1 -1
  48. package/dist/contracts/EarnVault.js +1262 -1292
  49. package/dist/contracts/EarnVaultAgent.d.ts.map +1 -1
  50. package/dist/contracts/EarnVaultAgent.js +745 -760
  51. package/dist/contracts/EarnVaultAgentSigHelper.d.ts.map +1 -1
  52. package/dist/contracts/EarnVaultAgentSigHelper.js +665 -665
  53. package/dist/contracts/Euler.d.ts.map +1 -1
  54. package/dist/contracts/Euler.js +1948 -1975
  55. package/dist/contracts/ExtraFi.d.ts.map +1 -1
  56. package/dist/contracts/ExtraFi.js +1929 -1953
  57. package/dist/contracts/Fluid.d.ts.map +1 -1
  58. package/dist/contracts/Fluid.js +1927 -1951
  59. package/dist/contracts/FortyAcres.d.ts.map +1 -1
  60. package/dist/contracts/FortyAcres.js +1916 -1940
  61. package/dist/contracts/Hatchery.d.ts.map +1 -1
  62. package/dist/contracts/Hatchery.js +255 -264
  63. package/dist/contracts/Helpers.d.ts.map +1 -1
  64. package/dist/contracts/Helpers.js +1069 -1123
  65. package/dist/contracts/HighCommand.d.ts.map +1 -1
  66. package/dist/contracts/HighCommand.js +1395 -1407
  67. package/dist/contracts/Kernel.d.ts.map +1 -1
  68. package/dist/contracts/Kernel.js +224 -236
  69. package/dist/contracts/Ledger.d.ts +9 -12
  70. package/dist/contracts/Ledger.d.ts.map +1 -1
  71. package/dist/contracts/Ledger.js +480 -486
  72. package/dist/contracts/LegoBook.d.ts.map +1 -1
  73. package/dist/contracts/LegoBook.js +1069 -1123
  74. package/dist/contracts/LegoTools.d.ts +16 -22
  75. package/dist/contracts/LegoTools.d.ts.map +1 -1
  76. package/dist/contracts/LegoTools.js +1420 -1426
  77. package/dist/contracts/LevgVault.d.ts.map +1 -1
  78. package/dist/contracts/LevgVault.js +1544 -1580
  79. package/dist/contracts/LevgVaultAgent.d.ts.map +1 -1
  80. package/dist/contracts/LevgVaultAgent.js +1514 -1529
  81. package/dist/contracts/LevgVaultAgentSigHelper.d.ts.map +1 -1
  82. package/dist/contracts/LevgVaultAgentSigHelper.js +1769 -1769
  83. package/dist/contracts/LevgVaultHelper.d.ts.map +1 -1
  84. package/dist/contracts/LevgVaultHelper.js +732 -732
  85. package/dist/contracts/LevgVaultTools.d.ts.map +1 -1
  86. package/dist/contracts/LevgVaultTools.js +2118 -2118
  87. package/dist/contracts/LootDistributor.d.ts.map +1 -1
  88. package/dist/contracts/LootDistributor.js +753 -789
  89. package/dist/contracts/Migrator.d.ts.map +1 -1
  90. package/dist/contracts/Migrator.js +168 -174
  91. package/dist/contracts/MissionControl.d.ts.map +1 -1
  92. package/dist/contracts/MissionControl.js +956 -962
  93. package/dist/contracts/Moonwell.d.ts.map +1 -1
  94. package/dist/contracts/Moonwell.js +1918 -1942
  95. package/dist/contracts/Morpho.d.ts.map +1 -1
  96. package/dist/contracts/Morpho.js +1948 -1975
  97. package/dist/contracts/Paymaster.d.ts.map +1 -1
  98. package/dist/contracts/Paymaster.js +1203 -1224
  99. package/dist/contracts/RipeLego.d.ts.map +1 -1
  100. package/dist/contracts/RipeLego.js +2134 -2176
  101. package/dist/contracts/Sentinel.d.ts +32 -41
  102. package/dist/contracts/Sentinel.d.ts.map +1 -1
  103. package/dist/contracts/Sentinel.js +1398 -1398
  104. package/dist/contracts/SignatureHelper.d.ts.map +1 -1
  105. package/dist/contracts/SignatureHelper.js +3202 -3202
  106. package/dist/contracts/SignatureHelperV1.d.ts +1 -1
  107. package/dist/contracts/SignatureHelperV1.d.ts.map +1 -1
  108. package/dist/contracts/SignatureHelperV1.js +3223 -3223
  109. package/dist/contracts/SkyPsm.d.ts.map +1 -1
  110. package/dist/contracts/SkyPsm.js +1953 -1980
  111. package/dist/contracts/Switchboard.d.ts.map +1 -1
  112. package/dist/contracts/Switchboard.js +1085 -1139
  113. package/dist/contracts/SwitchboardAlpha.d.ts.map +1 -1
  114. package/dist/contracts/SwitchboardAlpha.js +2333 -2474
  115. package/dist/contracts/SwitchboardBravo.d.ts.map +1 -1
  116. package/dist/contracts/SwitchboardBravo.js +1138 -1216
  117. package/dist/contracts/SwitchboardCharlie.d.ts.map +1 -1
  118. package/dist/contracts/SwitchboardCharlie.js +2295 -2475
  119. package/dist/contracts/UnderscoreLego.d.ts.map +1 -1
  120. package/dist/contracts/UnderscoreLego.js +1894 -1918
  121. package/dist/contracts/UndyAero.d.ts.map +1 -1
  122. package/dist/contracts/UndyAero.js +1342 -1372
  123. package/dist/contracts/UndyBtc.d.ts.map +1 -1
  124. package/dist/contracts/UndyBtc.js +1342 -1372
  125. package/dist/contracts/UndyCbeth.d.ts.map +1 -1
  126. package/dist/contracts/UndyCbeth.js +1342 -1372
  127. package/dist/contracts/UndyEth.d.ts.map +1 -1
  128. package/dist/contracts/UndyEth.js +1342 -1372
  129. package/dist/contracts/UndyEurc.d.ts.map +1 -1
  130. package/dist/contracts/UndyEurc.js +1342 -1372
  131. package/dist/contracts/UndyGho.d.ts.map +1 -1
  132. package/dist/contracts/UndyGho.js +1342 -1372
  133. package/dist/contracts/UndyHq.d.ts.map +1 -1
  134. package/dist/contracts/UndyHq.js +1234 -1300
  135. package/dist/contracts/UndyRewardsLego.d.ts.map +1 -1
  136. package/dist/contracts/UndyRewardsLego.js +1120 -1120
  137. package/dist/contracts/UndyUsd.d.ts.map +1 -1
  138. package/dist/contracts/UndyUsd.js +1342 -1372
  139. package/dist/contracts/UndyUsds.d.ts.map +1 -1
  140. package/dist/contracts/UndyUsds.js +1342 -1372
  141. package/dist/contracts/UndyVirtual.d.ts.map +1 -1
  142. package/dist/contracts/UndyVirtual.js +1363 -1396
  143. package/dist/contracts/UniswapV2.d.ts.map +1 -1
  144. package/dist/contracts/UniswapV2.js +1518 -1533
  145. package/dist/contracts/UniswapV3.d.ts.map +1 -1
  146. package/dist/contracts/UniswapV3.js +1620 -1641
  147. package/dist/contracts/UserWallet.d.ts.map +1 -1
  148. package/dist/contracts/UserWallet.js +1999 -2005
  149. package/dist/contracts/UserWalletConfig.d.ts.map +1 -1
  150. package/dist/contracts/UserWalletConfig.js +2572 -2593
  151. package/dist/contracts/UserWalletConfigV1.d.ts.map +1 -1
  152. package/dist/contracts/UserWalletConfigV1.js +2327 -2348
  153. package/dist/contracts/UserWalletSignatureHelper.d.ts +1 -1
  154. package/dist/contracts/UserWalletSignatureHelper.d.ts.map +1 -1
  155. package/dist/contracts/UserWalletSignatureHelper.js +3458 -3458
  156. package/dist/contracts/UserWalletV1.d.ts.map +1 -1
  157. package/dist/contracts/UserWalletV1.js +1914 -1920
  158. package/dist/contracts/VaultRegistry.d.ts +11 -14
  159. package/dist/contracts/VaultRegistry.d.ts.map +1 -1
  160. package/dist/contracts/VaultRegistry.js +2343 -2439
  161. package/dist/contracts/WalletBackpack.d.ts.map +1 -1
  162. package/dist/contracts/WalletBackpack.js +926 -965
  163. package/dist/contracts/Wasabi.d.ts.map +1 -1
  164. package/dist/contracts/Wasabi.js +1916 -1940
  165. package/dist/contracts/sdk.d.ts +8 -8
  166. package/dist/contracts/sdk.d.ts.map +1 -1
  167. package/dist/contracts/sdk.js +8 -8
  168. package/dist/index.d.ts.map +1 -1
  169. package/dist/index.js +9 -5
  170. package/package.json +44 -24
  171. package/LICENSE +0 -41
  172. package/dist/contracts/Agent.d.ts +0 -3773
  173. package/dist/contracts/Agent.d.ts.map +0 -1
  174. package/dist/contracts/Agent.js +0 -4942
  175. package/dist/getContracts.d.ts +0 -77
  176. package/dist/getContracts.d.ts.map +0 -1
  177. package/dist/getContracts.js +0 -64
package/AGENTS.md ADDED
@@ -0,0 +1,161 @@
1
+ <!-- dappql:start -->
2
+ <!-- Autogenerated by `dappql` from dapp.config.js — don't hand-edit between the dappql markers. Re-run `dappql` after config changes. -->
3
+
4
+ # DappQL — project context for AI agents
5
+
6
+ This project reads and writes on-chain state via **[DappQL](https://github.com/dappql/core)**, an agent-native data layer on wagmi + viem that makes smart contracts fluent for humans and agents. Use it for every contract interaction; don't reach for raw wagmi/viem primitives when a DappQL hook exists.
7
+
8
+ Full agent reference: https://github.com/dappql/core/blob/main/AGENTS.md
9
+
10
+ ## Generated setup
11
+
12
+ - Contracts directory: `./src/contracts`
13
+ - Module system: ESM
14
+ - SDK factory: yes — `./src/contracts/sdk` exports `createSdk(publicClient, walletClient, addressResolver)`
15
+ - Chain ID: 8453
16
+
17
+ ## Contracts in this project
18
+
19
+ | Contract | Shape | Reads | Writes | Events |
20
+ | --- | --- | --- | --- | --- |
21
+ | `AaveV3` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `depositForYield`, `withdrawFromYield`, … (+14) | `AaveV3Deposit`, `AaveV3Withdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved` |
22
+ | `AeroClassic` | singleton | `getAddys`, `getUndyHq`, `legoId`, `isPaused`, `hasCapability`, `getRegistries`, `isYieldLego`, `isDexLego`, … (+17) | `pause`, `recoverFunds`, `recoverFundsMany`, `swapTokens`, `addLiquidity`, `removeLiquidity`, `depositForYield`, `withdrawFromYield`, … (+10) | `AerodromeSwap`, `AerodromeLiquidityAdded`, `AerodromeLiquidityRemoved`, `LegoPauseModified`, `LegoFundsRecovered` |
23
+ | `AeroSlipstream` | singleton | `getAddys`, `getUndyHq`, `legoId`, `isPaused`, `hasCapability`, `onERC721Received`, `getRegistries`, `isYieldLego`, … (+15) | `pause`, `recoverFunds`, `recoverFundsMany`, `swapTokens`, `uniswapV3SwapCallback`, `addLiquidityConcentrated`, `removeLiquidityConcentrated`, `getBestSwapAmountOut`, … (+16) | `AeroSlipStreamSwap`, `AeroSlipStreamLiquidityAdded`, `AeroSlipStreamLiquidityRemoved`, `AeroSlipStreamNftRecovered`, `AeroSlipstreamFeesCollected`, `LegoPauseModified`, `LegoFundsRecovered` |
24
+ | `AgentSenderGeneric` | template | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `getNonce`, `currentNonce` | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `transferFunds`, `createAndPayCheque`, `depositForYield`, `withdrawFromYield`, … (+17) | `NonceIncremented`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
25
+ | `AgentSenderSpecial` | template | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `getNonce`, `currentNonce`, … (+3) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `addCollateralAndBorrow`, `repayAndWithdraw`, `rebalanceYieldPositionsWithSwap`, `claimIncentivesAndSwap`, … (+1) | `NonceIncremented`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
26
+ | `AgentSenderSpecialSigHelper` | template | `getAddCollateralAndBorrowHash`, `getRepayAndWithdrawHash`, `getRebalanceYieldPositionsWithSwapHash`, `getClaimIncentivesAndSwapHash` | — | — |
27
+ | `AgentWrapper` | template | `isSender`, `groupId`, `senders`, `indexOfSender`, `numSenders` | `transferFunds`, `createAndPayCheque`, `depositForYield`, `withdrawFromYield`, `rebalanceYieldPosition`, `swapTokens`, `mintOrRedeemAsset`, `confirmMintOrRedeemAsset`, … (+13) | `AgentAction` |
28
+ | `AgentWrapperV1` | template | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `getNonce`, `groupId`, … (+1) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `transferFunds`, `depositForYield`, `withdrawFromYield`, `rebalanceYieldPosition`, … (+16) | `NonceIncremented`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
29
+ | `AgentWrapperV2` | template | `isSender`, `groupId`, `senders`, `indexOfSender`, `numSenders` | `transferFunds`, `depositForYield`, `withdrawFromYield`, `rebalanceYieldPosition`, `swapTokens`, `mintOrRedeemAsset`, `confirmMintOrRedeemAsset`, `addCollateral`, … (+12) | `AgentAction` |
30
+ | `Appraiser` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `calculateYieldProfitsNoUpdate`, `lastPricePerShare`, `getUsdValue`, `getUnderlyingUsdValue`, … (+2) | `pause`, `recoverFunds`, `recoverFundsMany`, `calculateYieldProfits`, `updatePriceAndGetUsdValue`, `updatePriceAndGetUsdValueAndIsYieldAsset` | `DepartmentPauseModified`, `DepartmentFundsRecovered` |
31
+ | `Avantis` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+37) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `AvantisDeposit`, `AvantisWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
32
+ | `Billing` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `canPullPaymentAsCheque`, `canPullPaymentAsPayee` | `pause`, `recoverFunds`, `recoverFundsMany`, `pullPaymentAsCheque`, `pullPaymentAsPayee` | `ChequePaymentPulled`, `PayeePaymentPulled`, `DepartmentPauseModified`, `DepartmentFundsRecovered` |
33
+ | `ChequeBook` | singleton | `canCreateCheque`, `isValidNewCheque`, `isValidChequeSettings`, `getChequeConfig`, `createDefaultChequeSettings`, `UNDY_HQ`, `MIN_CHEQUE_PERIOD`, `MAX_CHEQUE_PERIOD`, … (+3) | `createCheque`, `cancelCheque`, `setChequeSettings` | `ChequeCreated`, `ChequeCancelled`, `ChequeSettingsModified` |
34
+ | `CompoundV3` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+37) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `depositForYield`, `withdrawFromYield`, … (+16) | `CompoundV3Deposit`, `CompoundV3Withdrawal`, `CompoundV3RewardsAddrSet`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved` |
35
+ | `ConvertVaultToken` | singleton | — | `convertVaultToken` | — |
36
+ | `Curve` | singleton | `getAddys`, `getUndyHq`, `legoId`, `isPaused`, `hasCapability`, `getRegistries`, `isYieldLego`, `isDexLego`, … (+16) | `pause`, `recoverFunds`, `recoverFundsMany`, `swapTokens`, `addLiquidity`, `removeLiquidity` | `CurveSwap`, `CurveLiquidityAdded`, `CurveLiquidityRemoved`, `LegoPauseModified`, `LegoFundsRecovered` |
37
+ | `DefaultsBase` | singleton | `userWalletConfig`, `agentConfig`, `managerConfig`, `payeeConfig`, `chequeConfig`, `ripeRewardsConfig`, `securitySigners`, `whitelistedCreators` | — | — |
38
+ | `ERC20` | template | `name`, `symbol`, `decimals`, `totalSupply`, `balanceOf`, `allowance`, `nonces`, `DOMAIN_SEPARATOR` | `transfer`, `transferFrom`, `approve`, `permit` | `Transfer`, `Approval` |
39
+ | `EarnVault` | template | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
40
+ | `EarnVaultAgent` | singleton | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `getNonce`, `groupId`, … (+1) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `depositForYield`, `withdrawFromYield`, `swapTokens`, `claimIncentives`, … (+2) | `NonceIncremented`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
41
+ | `EarnVaultAgentSigHelper` | singleton | `getDepositForYieldHash`, `getWithdrawFromYieldHash`, `getSwapTokensHash`, `getClaimIncentivesHash`, `getBatchActionsHash` | — | — |
42
+ | `Euler` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+39) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+15) | `EulerDeposit`, `EulerWithdrawal`, `EulerRewardsAddrSet`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, … (+1) |
43
+ | `ExtraFi` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `registerVaultTokensGlobally`, `addPriceSnapshot`, … (+15) | `ExtraFiDeposit`, `ExtraFiWithdrawal`, `AssetOpportunityAdded`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
44
+ | `Fluid` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+39) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `FluidDeposit`, `FluidWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
45
+ | `FortyAcres` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `FortyAcresDeposit`, `FortyAcresWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
46
+ | `Hatchery` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `doesWalletStillHaveTrialFundsWithAddys`, `WETH`, `ETH` | `pause`, `recoverFunds`, `recoverFundsMany`, `createUserWallet` | `UserWalletCreated`, `DepartmentPauseModified`, `DepartmentFundsRecovered` |
47
+ | `Helpers` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+31) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setRegistryTimeLock`, `setRegistryTimeLockAfterSetup`, … (+12) | `GovChangeTimeLockModified`, `RegistryTimeLockModified`, `GovChangeStarted`, `GovChangeConfirmed`, `GovChangeCancelled`, `GovRelinquished`, `UndyHqSetupFinished`, `DepartmentPauseModified`, … (+10) |
48
+ | `HighCommand` | singleton | `isValidNewManager`, `validateManagerOnUpdate`, `validateGlobalManagerSettings`, `createDefaultGlobalManagerSettings`, `createStarterAgentSettings`, `getManagerSettingsBundle`, `UNDY_HQ`, `MIN_MANAGER_PERIOD`, … (+4) | `addManager`, `updateManager`, `removeManager`, `adjustManagerActivationLength`, `setGlobalManagerSettings` | `GlobalManagerSettingsModified`, `ManagerSettingsModified`, `ManagerRemoved`, `ManagerActivationLengthAdjusted` |
49
+ | `Kernel` | singleton | `canManageWhitelist`, `getWhitelistConfig`, `UNDY_HQ` | `addPendingWhitelistAddr`, `confirmWhitelistAddr`, `cancelPendingWhitelistAddr`, `removeWhitelistAddr` | `WhitelistAddrPending`, `WhitelistAddrConfirmed`, `WhitelistAddrCancelled`, `WhitelistAddrRemoved` |
50
+ | `Ledger` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `getNumUserWallets`, `isUserWallet`, `getLastTotalUsdValue`, `getUserAndGlobalPoints`, … (+14) | `pause`, `recoverFunds`, `recoverFundsMany`, `createUserWallet`, `setUserPoints`, `setGlobalPoints`, `setUserAndGlobalPoints`, `setVaultToken`, … (+2) | `DepartmentPauseModified`, `DepartmentFundsRecovered` |
51
+ | `LegoBook` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+31) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setRegistryTimeLock`, `setRegistryTimeLockAfterSetup`, … (+12) | `GovChangeTimeLockModified`, `RegistryTimeLockModified`, `GovChangeStarted`, `GovChangeConfirmed`, `GovChangeCancelled`, `GovRelinquished`, `UndyHqSetupFinished`, `DepartmentPauseModified`, … (+10) |
52
+ | `LegoTools` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `aaveV3`, `aaveV3Id`, `compoundV3`, `compoundV3Id`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `getRoutesAndSwapInstructionsAmountOut`, `getRoutesAndSwapInstructionsAmountIn`, `prepareSwapInstructionsAmountOut`, `getBestSwapRoutesAmountOut`, `getBestSwapAmountOutWithRouterPool`, … (+6) | `DepartmentPauseModified`, `DepartmentFundsRecovered` |
53
+ | `LevgVault` | template | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+35) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+24) | `Deposit`, `Withdraw`, `LeftoversSwept`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `LevgVaultAction`, … (+5) |
54
+ | `LevgVaultAgent` | singleton | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `getNonce`, `UNDY_HQ`, … (+3) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `borrowAndEarnYield`, `deleverage`, `compoundYieldGains`, `incrementNonce` | `NonceIncremented`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
55
+ | `LevgVaultAgentSigHelper` | singleton | `getBorrowAndEarnYieldHash`, `getDeleverageHash`, `getCompoundYieldGainsHash` | — | — |
56
+ | `LevgVaultHelper` | template | `getAddys`, `getUndyHq`, `getSwappableUsdcAmount`, `getMaxBorrowAmount`, `performPostSwapValidation`, `getTotalAssetsForUsdcVault`, `getTotalAssetsForNonUsdcVault`, `getCollateralBalance`, … (+8) | — | — |
57
+ | `LevgVaultTools` | singleton | `getAddys`, `getUndyHq`, `getTotalUnderlyingAmount`, `getAmountForAsset`, `getUnderlyingAmountForVaultToken`, `getRipeCollateralBalance`, `getUnderlyingGreenAmount`, `getSavingsGreenBalances`, … (+18) | — | — |
58
+ | `LootDistributor` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `getClaimableLootForAsset`, `getTotalClaimableAssets`, `getLatestDepositPoints`, `isValidWalletConfig`, … (+13) | `pause`, `recoverFunds`, `recoverFundsMany`, `addLootFromSwapOrRewards`, `addLootFromYieldProfit`, `claimRevShareAndBonusLoot`, `adjustLoot`, `updateDepositPoints`, … (+6) | `TransactionFeePaid`, `RevenueTransferredToGov`, `YieldPerformanceFeePaid`, `AmbassadorTxFeePaid`, `YieldBonusPaid`, `LootAdjusted`, `LootClaimed`, `DepositRewardsAdded`, … (+4) |
59
+ | `Migrator` | singleton | `canMigrateFundsToNewWallet`, `canCopyWalletConfig`, `getMigrationConfigBundle`, `UNDY_HQ` | `migrateAll`, `migrateFunds`, `cloneConfig` | `FundsMigrated`, `ConfigCloned` |
60
+ | `MissionControl` | singleton | `getAddys`, `getUndyHq`, `canMintUndy`, `isPaused`, `getUserWalletCreationConfig`, `getDepositRewardsAsset`, `getLootClaimCoolOffPeriod`, `getRipeRewardsConfig`, … (+22) | `pause`, `recoverFunds`, `recoverFundsMany`, `setUserWalletConfig`, `setManagerConfig`, `setPayeeConfig`, `setChequeConfig`, `setRipeRewardsConfig`, … (+7) | `DepartmentPauseModified`, `DepartmentFundsRecovered` |
61
+ | `Moonwell` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `MoonwellDeposit`, `MoonwellWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
62
+ | `Morpho` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+39) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+15) | `MorphoDeposit`, `MorphoWithdrawal`, `MorphoRewardsAddrSet`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, … (+1) |
63
+ | `Paymaster` | singleton | `isValidNewPayee`, `isValidPayeeUpdate`, `canAddPendingPayee`, `isValidGlobalPayeeSettings`, `getPayeeConfig`, `createDefaultGlobalPayeeSettings`, `UNDY_HQ`, `MIN_PAYEE_PERIOD`, … (+4) | `setGlobalPayeeSettings`, `addPayee`, `updatePayee`, `removePayee`, `addPendingPayee`, `confirmPendingPayee`, `cancelPendingPayee` | `PayeeAdded`, `PayeeUpdated`, `PayeeRemoved`, `GlobalPayeeSettingsModified`, `PayeePending`, `PayeePendingConfirmed`, `PayeePendingCancelled` |
64
+ | `RipeLego` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+41) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+16) | `RipeCollateralDeposit`, `RipeCollateralWithdrawal`, `RipeBorrow`, `RipeRepay`, `RipeClaimRewards`, `RipeSavingsGreenDeposit`, `RipeSavingsGreenWithdrawal`, `RipeEndaomentPsmSwap`, … (+6) |
65
+ | `Sentinel` | singleton | `canSignerPerformAction`, `canSignerPerformActionWithConfig`, `canManagerFinishTx`, `checkManagerLimitsPostTx`, `isValidPayee`, `isValidPayeeAndGetData`, `isValidChequeAndGetData` | — | — |
66
+ | `SignatureHelper` | singleton | `getTransferFundsHash`, `getDepositForYieldHash`, `getWithdrawFromYieldHash`, `getRebalanceYieldPositionHash`, `getSwapTokensHash`, `getMintOrRedeemAssetHash`, `getConfirmMintOrRedeemAssetHash`, `getAddCollateralHash`, … (+11) | — | — |
67
+ | `SignatureHelperV1` | template | `getTransferFundsHash`, `getDepositForYieldHash`, `getWithdrawFromYieldHash`, `getRebalanceYieldPositionHash`, `getSwapTokensHash`, `getMintOrRedeemAssetHash`, `getConfirmMintOrRedeemAssetHash`, `getAddCollateralHash`, … (+11) | — | — |
68
+ | `SkyPsm` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+40) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+15) | `SkyPsmDeposit`, `SkyPsmWithdrawal`, `SlippageSet`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, … (+1) |
69
+ | `Switchboard` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+31) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setRegistryTimeLock`, `setRegistryTimeLockAfterSetup`, … (+13) | `GovChangeTimeLockModified`, `RegistryTimeLockModified`, `GovChangeStarted`, `GovChangeConfirmed`, `GovChangeCancelled`, `GovRelinquished`, `UndyHqSetupFinished`, `DepartmentPauseModified`, … (+10) |
70
+ | `SwitchboardAlpha` | singleton | `getAddys`, `getUndyHq`, `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, … (+29) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setActionTimeLock`, `setExpiration`, … (+23) | `PendingUserWalletTemplatesChange`, `UserWalletTemplatesSet`, `PendingWalletCreationLimitsChange`, `WalletCreationLimitsSet`, `PendingKeyActionTimelockBoundsChange`, `KeyActionTimelockBoundsSet`, `PendingTxFeesChange`, `TxFeesSet`, … (+39) |
71
+ | `SwitchboardBravo` | singleton | `getAddys`, `getUndyHq`, `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, … (+24) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setActionTimeLock`, `setExpiration`, … (+15) | `PendingRecoverFundsAction`, `PendingRecoverFundsManyAction`, `PendingRecoverNftAction`, `PendingLootAdjustAction`, `PendingRecoverDepositRewardsAction`, `AssetDataUpdated`, `AllAssetDataUpdated`, `PendingSetEjectionModeAction`, … (+18) |
72
+ | `SwitchboardCharlie` | singleton | `getAddys`, `getUndyHq`, `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, … (+37) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setActionTimeLock`, `setExpiration`, … (+35) | `PendingRedemptionBufferChange`, `RedemptionBufferSet`, `PendingMinYieldWithdrawAmountChange`, `MinYieldWithdrawAmountSet`, `PendingSnapShotPriceConfigChange`, `SnapShotPriceConfigSet`, `PendingApprovedVaultTokenChange`, `ApprovedVaultTokenSet`, … (+52) |
73
+ | `UnderscoreLego` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+36) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `UnderscoreEarnVaultDeposit`, `UnderscoreEarnVaultWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
74
+ | `UndyAero` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
75
+ | `UndyBtc` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
76
+ | `UndyCbeth` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
77
+ | `UndyEth` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
78
+ | `UndyEurc` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
79
+ | `UndyGho` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
80
+ | `UndyHq` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+34) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setRegistryTimeLock`, `setRegistryTimeLockAfterSetup`, … (+16) | `HqConfigChangeInitiated`, `HqConfigChangeConfirmed`, `HqConfigChangeCancelled`, `UndyHqFundsRecovered`, `UndyTokenSet`, `MintingEnabled`, `GovChangeTimeLockModified`, `RegistryTimeLockModified`, … (+14) |
81
+ | `UndyRewardsLego` | singleton | `getAddys`, `getUndyHq`, `hasClaimableRewards`, `hasCapability`, `getRegistries`, `isDexLego`, `isYieldLego`, `isPaused`, … (+3) | `claimRewards`, `pause`, `recoverFunds`, `recoverFundsMany`, `depositForYield`, `withdrawFromYield`, `swapTokens`, `mintOrRedeemAsset`, … (+9) | — |
82
+ | `UndyUsd` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
83
+ | `UndyUsds` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+16) | `Deposit`, `Withdraw`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, `EarnVaultWithdrawal`, … (+3) |
84
+ | `UndyVirtual` | singleton | `name`, `symbol`, `decimals`, `DOMAIN_SEPARATOR`, `undyHq`, `blacklisted`, `isPaused`, `balanceOf`, … (+32) | `transfer`, `transferFrom`, `approve`, `increaseAllowance`, `decreaseAllowance`, `burn`, `permit`, `setBlacklist`, … (+17) | `Deposit`, `Withdraw`, `LeftoversSwept`, `Transfer`, `Approval`, `BlacklistModified`, `TokenPauseModified`, `EarnVaultDeposit`, … (+4) |
85
+ | `UniswapV2` | singleton | `getAddys`, `getUndyHq`, `legoId`, `isPaused`, `hasCapability`, `getRegistries`, `isYieldLego`, `isDexLego`, … (+17) | `pause`, `recoverFunds`, `recoverFundsMany`, `swapTokens`, `addLiquidity`, `removeLiquidity`, `depositForYield`, `withdrawFromYield`, … (+10) | `UniswapV2Swap`, `UniswapV2LiquidityAdded`, `UniswapV2LiquidityRemoved`, `LegoPauseModified`, `LegoFundsRecovered` |
86
+ | `UniswapV3` | singleton | `getAddys`, `getUndyHq`, `legoId`, `isPaused`, `hasCapability`, `onERC721Received`, `getRegistries`, `isYieldLego`, … (+15) | `pause`, `recoverFunds`, `recoverFundsMany`, `swapTokens`, `uniswapV3SwapCallback`, `addLiquidityConcentrated`, `removeLiquidityConcentrated`, `getBestSwapAmountOut`, … (+16) | `UniswapV3Swap`, `UniswapV3LiquidityAdded`, `UniswapV3LiquidityRemoved`, `UniswapV3NftRecovered`, `UniswapV3FeesCollected`, `LegoPauseModified`, `LegoFundsRecovered` |
87
+ | `UserWallet` | template | `onERC721Received`, `apiVersion`, `walletConfig`, `assetData`, `assets`, `indexOfAsset`, `numAssets`, `WETH`, … (+1) | `transferFunds`, `depositForYield`, `withdrawFromYield`, `rebalanceYieldPosition`, `swapTokens`, `mintOrRedeemAsset`, `confirmMintOrRedeemAsset`, `addCollateral`, … (+14) | `WalletAction`, `WalletActionExt` |
88
+ | `UserWalletConfig` | template | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `apiVersion`, `checkSignerPermissionsAndGetBundle`, … (+41) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `setWallet`, `checkManagerLimitsPostTx`, `checkRecipientLimitsAndUpdateData`, `validateCheque`, … (+34) | `EjectionModeSet`, `FrozenSet`, `NftRecovered`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
89
+ | `UserWalletConfigV1` | template | `hasPendingOwnerChange`, `owner`, `ownershipTimeLock`, `pendingOwner`, `MIN_OWNERSHIP_TIMELOCK`, `MAX_OWNERSHIP_TIMELOCK`, `apiVersion`, `checkSignerPermissionsAndGetBundle`, … (+43) | `changeOwnership`, `confirmOwnershipChange`, `cancelOwnershipChange`, `setOwnershipTimeLock`, `setWallet`, `checkManagerUsdLimitsAndUpdateData`, `checkRecipientLimitsAndUpdateData`, `validateCheque`, … (+35) | `EjectionModeSet`, `FrozenSet`, `NftRecovered`, `OwnershipChangeInitiated`, `OwnershipChangeConfirmed`, `OwnershipChangeCancelled`, `OwnershipTimeLockSet` |
90
+ | `UserWalletSignatureHelper` | template | `getTransferFundsHash`, `getCreateAndPayChequeHash`, `getDepositForYieldHash`, `getWithdrawFromYieldHash`, `getRebalanceYieldPositionHash`, `getSwapTokensHash`, `getMintOrRedeemAssetHash`, `getConfirmMintOrRedeemAssetHash`, … (+13) | — | — |
91
+ | `UserWalletV1` | template | `onERC721Received`, `apiVersion`, `walletConfig`, `assetData`, `assets`, `indexOfAsset`, `numAssets`, `WETH`, … (+1) | `transferFunds`, `depositForYield`, `withdrawFromYield`, `rebalanceYieldPosition`, `swapTokens`, `mintOrRedeemAsset`, `confirmMintOrRedeemAsset`, `addCollateral`, … (+14) | `WalletAction`, `WalletActionExt` |
92
+ | `VaultRegistry` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+74) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `setRegistryTimeLock`, `setRegistryTimeLockAfterSetup`, … (+24) | `CanDepositSet`, `CanWithdrawSet`, `MaxDepositAmountSet`, `VaultOpsFrozenSet`, `RedemptionBufferSet`, `MinYieldWithdrawAmountSet`, `PerformanceFeeSet`, `DefaultTargetVaultTokenSet`, … (+24) |
93
+ | `WalletBackpack` | singleton | `getUndyHqFromGov`, `canGovern`, `getGovernors`, `hasPendingGovChange`, `isValidGovTimeLock`, `minGovChangeTimeLock`, `maxGovChangeTimeLock`, `governance`, … (+27) | `startGovernanceChange`, `confirmGovernanceChange`, `cancelGovernanceChange`, `relinquishGov`, `setGovTimeLock`, `finishUndyHqSetup`, `pause`, `recoverFunds`, … (+22) | `PendingBackpackItemAdded`, `BackpackItemConfirmed`, `PendingBackpackItemCancelled`, `GovChangeTimeLockModified`, `ExpirationSet`, `ActionTimeLockSet`, `GovChangeStarted`, `GovChangeConfirmed`, … (+5) |
94
+ | `Wasabi` | singleton | `getAddys`, `getUndyHq`, `isLegoAsset`, `getAssetOpportunities`, `getAssets`, `isAssetOpportunity`, `getNumLegoAssets`, `getWeightedPricePerShare`, … (+38) | `pause`, `recoverFunds`, `recoverFundsMany`, `setSnapShotPriceConfig`, `registerVaultTokenLocally`, `deregisterVaultTokenLocally`, `addPriceSnapshot`, `depositForYield`, … (+14) | `WasabiDeposit`, `WasabiWithdrawal`, `LegoPauseModified`, `LegoFundsRecovered`, `SnapShotPriceConfigSet`, `AssetOpportunityAdded`, `AssetOpportunityRemoved`, `PricePerShareSnapShotAdded` |
95
+
96
+ *singleton = fixed `deployAddress` baked in. template = pass the address per use via `.at(addr)` in React or `sdk.Contract(addr)` in the SDK factory.*
97
+
98
+ ## Use it
99
+
100
+ ### React — prefer `useContextQuery` (batches across the whole tree)
101
+
102
+ ```tsx
103
+ import { AaveV3 } from './src/contracts'
104
+ import { useContextQuery } from '@dappql/react'
105
+
106
+ const { data, isLoading } = useContextQuery({
107
+ getAddys: AaveV3.call.getAddys(),
108
+ getUndyHq: AaveV3.call.getUndyHq(),
109
+ })
110
+ ```
111
+
112
+ ### React — mutations
113
+
114
+ ```tsx
115
+ import { AeroClassic } from './src/contracts'
116
+ import { useMutation } from '@dappql/react'
117
+
118
+ const tx = useMutation(AeroClassic.mutation.pause, 'pause')
119
+ tx.send(/* _shouldPause */)
120
+ ```
121
+
122
+ ### Template contracts
123
+
124
+ ```ts
125
+ // Template contract — bind the address per call
126
+ AgentSenderGeneric.call.hasPendingOwnerChange().at(contractAddress)
127
+ ```
128
+
129
+ ### Non-React — generated SDK factory
130
+
131
+ ```ts
132
+ import createSdk from './src/contracts/sdk'
133
+
134
+ const sdk = createSdk(publicClient, walletClient)
135
+ const value = await sdk.AaveV3.getAddys()
136
+ const bound = sdk.AgentSenderGeneric('0x...') // template: pass address
137
+ const result = await bound.hasPendingOwnerChange()
138
+ ```
139
+
140
+ ### Non-React — ad-hoc multicall
141
+
142
+ ```ts
143
+ import { query } from '@dappql/async'
144
+ import { AaveV3 } from './src/contracts'
145
+
146
+ const { data } = await query(publicClient, {
147
+ value: AaveV3.call.getAddys(),
148
+ })
149
+ ```
150
+
151
+ ## Non-negotiables
152
+
153
+ - **Always import from `./src/contracts`.** Never hand-craft ABIs or hardcode addresses already in the config. Re-run `dappql` after editing `dapp.config.js`.
154
+ - **Never use `useReadContract` / `useReadContracts` / `useWriteContract` directly** when you can use `useContextQuery` / `useQuery` / `useMutation`. The batching and typing layer is the whole point.
155
+ - **Default to `useContextQuery`** over `useQuery` — it fuses calls across the component tree into one RPC.
156
+ - **`uint256` is `bigint`.** Use `0n`, `1n`, `BigInt(n)`. Never pass plain numbers where `bigint` is expected.
157
+ - **Addresses are `\`0x${string}\``.** Checksum untrusted input via viem's `getAddress`.
158
+ - **Mutation `send` takes spread args**: `tx.send(a, b, c)`, not `tx.send([a, b, c])`.
159
+ - **Template contracts require an address** per use — use `.at(addr)` on the call builder or `sdk.Contract(addr)` in the SDK factory.
160
+
161
+ <!-- dappql:end -->
package/README.md CHANGED
@@ -1,131 +1,32 @@
1
- # Underscore Smart Contracts SDK
1
+ # @underscore-finance/sdk
2
2
 
3
- A TypeScript SDK for interacting with Underscore's AI-driven smart contracts on Base network. Underscore enables trustless AI agents to operate on your behalf in DeFi—securely, transparently, and within boundaries you define.
3
+ SDK for interacting with Underscore Finance Smart Contracts with TypeScript
4
4
 
5
- ## Key Features
6
-
7
- - **Non-Custodial**: Retain full control of your assets; only you can transfer or withdraw funds
8
- - **Granular Control**: Define precise boundaries for AI agent operations
9
- - **Rule-Based Autonomy**: Smart contracts strictly enforce your parameters
10
- - **Minimal Trust**: Built on open-source, immutable code
11
- - **Extensible**: Add new DeFi protocol integrations without migrating funds
12
- - **Auditability**: Fully transparent, verifiable code
13
-
14
- ## Installation
5
+ ## Install
15
6
 
16
7
  ```bash
17
- npm install @underscore-finance/sdk viem
18
- # or
19
- yarn add @underscore-finance/sdk viem
20
- ```
21
-
22
- ## Quick Start
23
-
24
- ```typescript
25
- import Underscore from '@underscore-finance/sdk'
26
- import { createWalletClient, custom } from 'viem'
27
- import { base } from 'viem/chains'
28
-
29
- // Initialize SDK = Read mode only
30
- const underscore = new Underscore()
31
-
32
- // For AI agent operations, initialize with a wallet client
33
- const underscore = new Underscore({
34
- walletClient: createWalletClient({
35
- chain: base,
36
- transport: custom(window.ethereum),
37
- }),
38
- })
39
-
40
- // Create an AI Wallet
41
- const createWallet = async (owner: string, aiAgent: string) => {
42
- return await underscore.Factory.createUserWallet(
43
- owner, // Your wallet address
44
- aiAgent, // AI agent's address
45
- )
46
- }
47
-
48
- // Configure AI permissions
49
- const configureAgent = async (agent: string, allowedAssets: string[]) => {
50
- for (const asset of allowedAssets) {
51
- await underscore.UserWalletConfig.at('0xWalletAddress').addAssetForAgent(agent, asset)
52
- }
53
- }
8
+ pnpm add @underscore-finance/sdk
54
9
  ```
55
10
 
56
- ## Core Components
57
-
58
- ### AI Agent System
59
-
60
- - `AgentFactory` - Deploy and manage AI wallets
61
- - `AgentTemplate` - Access to AI agent templates
62
- - `WalletConfig` - Set AI agent permissions and rules
63
- - `WalletFunds` - Manage wallet assets
64
- - `LegoHelper` - Set of helper functions to interact with legos
65
- - `OracleRegistry` - Registry for price feeds
66
-
67
- ### Protocol Integrations ("Legos")
11
+ ## Use with DappQL MCP
68
12
 
69
- Modular DeFi integrations your AI can interact with:
13
+ Once installed, `@dappql/mcp` auto-discovers this package as a plugin and exposes its contracts, ABIs, and SDK to your AI coding agent.
70
14
 
71
- - `LegoAaveV3` - Aave V3 lending/borrowing
72
- - `LegoCompoundV3` - Compound V3 operations
73
- - `LegoUniswapV3` - Uniswap V3 swaps
74
- - `LegoCurve` - Curve pool interactions
75
- - And many more protocol integrations
15
+ ## Use the SDK directly
76
16
 
77
- ### Price Feed Systems
17
+ ```ts
18
+ import createSdk from '@underscore-finance/sdk/sdk'
19
+ import { createPublicClient, http } from 'viem'
78
20
 
79
- Price oracles your AI can reference:
80
-
81
- - `ChainlinkFeeds` - Chainlink oracle data
82
- - `PythFeeds` - Pyth Network feeds
83
- - `StorkFeeds` - Stork protocol data
84
-
85
- ## Use Cases
86
-
87
- 1. **Autonomous Yield Farming**
88
-
89
- - AI monitors lending rates across protocols
90
- - Automatically shifts funds to optimal yields
91
- - Operates within your risk parameters
92
-
93
- 2. **Smart Portfolio Rebalancing**
94
-
95
- - AI maintains your desired asset ratios
96
- - Executes trades based on market conditions
97
- - Respects your defined boundaries
98
-
99
- 3. **Risk Management**
100
- - AI monitors on-chain risk indicators
101
- - Automatically adjusts positions
102
- - Follows your pre-set safety rules
103
-
104
- ## Configuration
105
-
106
- ```typescript
107
- interface UnderscoreConfig {
108
- rpcUrl?: string // Custom RPC URL for Base network
109
- publicClient?: PublicClient // Custom viem public client
110
- walletClient?: WalletClient // Required for transactions
111
- }
21
+ const publicClient = createPublicClient({ transport: http() })
22
+ const sdk = createSdk(publicClient)
112
23
  ```
113
24
 
114
- ## Best Practices
115
-
116
- 1. Always initialize with a wallet client for AI agent operations
117
- 2. Use custom RPC URLs in production
118
- 3. Implement comprehensive error handling
119
- 4. Set clear boundaries for AI agent actions
120
-
121
- ## Support
122
-
123
- - GitHub Issues: Technical support and bug reports
124
- - Discord Community: [Join our Discord](https://discord.gg/Y6PWmndNaC)
125
- - Developer Support: [Contact our team](https://underscore.fi)
25
+ ## Links
126
26
 
127
- ## License
27
+ - Website: https://underscore.finance
28
+ - Repo: https://github.com/underscore-finance/typescript-sdk
128
29
 
129
- Business Source License 1.1 - This SDK is provided under a commercial license. All rights reserved. Unauthorized copying, modification, distribution, or use of this software is strictly prohibited without a valid license agreement.
30
+ ---
130
31
 
131
- Built by the team at [Hightop](http://hightop.com) + [Ripe](http://ripe.finance)
32
+ Built with [DappQL](https://dappql.com).