@raac/rpc 1.2.0-beta.4 → 1.2.0-beta.6
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.
- package/dist/RPCLibrary.js +236 -83
- package/dist/artifacts/core/collectors/FeeCollector.sol/FeeCollector.json +2 -2
- package/dist/artifacts/core/collectors/NFTRoyaltyFeeCollector.sol/NFTRoyaltyFeeCollector.json +15 -2
- package/dist/artifacts/core/collectors/RAACTokenCollector.sol/RAACTokenCollector.json +2 -2
- package/dist/artifacts/core/collectors/RWAIndexTokenCollector.sol/RWAIndexTokenCollector.json +2 -2
- package/dist/artifacts/core/collectors/Treasury.sol/Treasury.json +2 -2
- package/dist/artifacts/core/governance/gauges/BaseGauge.sol/BaseGauge.json +144 -158
- package/dist/artifacts/core/governance/gauges/GaugeController.sol/GaugeController.json +119 -355
- package/dist/artifacts/core/governance/gauges/GaugeRewardsDistributor.sol/GaugeRewardsDistributor.json +104 -325
- package/dist/artifacts/core/governance/gauges/RAACGauge.sol/RAACGauge.json +156 -160
- package/dist/artifacts/core/governance/gauges/RWAGauge.sol/RWAGauge.json +156 -160
- package/dist/artifacts/core/governance/proposals/Governance.sol/Governance.json +2 -2
- package/dist/artifacts/core/governance/proposals/TimelockController.sol/TimelockController.json +2 -2
- package/dist/artifacts/core/lockers/RAACBotLocker.sol/RAACBotLocker.json +915 -0
- package/dist/artifacts/core/lockers/RAACLiquidLocker.sol/RAACLiquidLocker.json +2158 -0
- package/dist/artifacts/core/lockers/RAACMaturityVault.sol/RAACMaturityVault.json +911 -0
- package/dist/artifacts/core/minters/RAACMinter/RAACMinter.sol/RAACMinter.json +59 -741
- package/dist/artifacts/core/oracles/BaseVRFv2Consumer.sol/BaseVRFv2Consumer.json +106 -2
- package/dist/artifacts/core/oracles/CrvUSDToUSDOracle.sol/CrvUSDToUSDOracle.json +2 -2
- package/dist/artifacts/core/oracles/RAACHousePriceOracle.sol/RAACHousePriceOracle.json +2 -2
- package/dist/artifacts/core/oracles/RAACPrimeRateOracle.sol/RAACPrimeRateOracle.json +2 -2
- package/dist/artifacts/core/pools/LendingPool/ERC20AssetAdapter.sol/ERC20AssetAdapter.json +15 -2
- package/dist/artifacts/core/pools/LendingPool/ERC721AssetAdapter.sol/ERC721AssetAdapter.json +15 -2
- package/dist/artifacts/core/pools/LendingPool/LendingPool.sol/LendingPool.json +20 -49
- package/dist/artifacts/core/pools/StabilityPool/StabilityPool.sol/StabilityPool.json +2 -2
- package/dist/artifacts/core/primitives/ComplianceRegistry.sol/ComplianceRegistry.json +2 -2
- package/dist/artifacts/core/primitives/RAACHousePrices.sol/RAACHousePrices.json +2 -2
- package/dist/artifacts/core/tokens/DEToken.sol/DEToken.json +21 -2
- package/dist/artifacts/core/tokens/LeRAAC.sol/LiquidEscrowedRAAC.json +621 -0
- package/dist/artifacts/core/tokens/RAACNFT.sol/RAACNFT.json +101 -74
- package/dist/artifacts/core/tokens/RAACToken.sol/RAACToken.json +24 -322
- package/dist/artifacts/core/tokens/RToken.sol/RToken.json +2 -2
- package/dist/artifacts/core/tokens/RWAIndexToken.sol/RWAIndexToken.json +66 -2
- package/dist/artifacts/core/tokens/veRAACToken.sol/veRAACToken.json +79 -32
- package/dist/artifacts/core/vaults/ERC20VaultAdapter.sol/ERC20VaultAdapter.json +15 -2
- package/dist/artifacts/core/vaults/ERC721VaultAdapter.sol/ERC721VaultAdapter.json +15 -2
- package/dist/artifacts/core/vaults/RWAVault.sol/RWAVault.json +46 -2
- package/dist/artifacts/mocks/core/oracles/MockVRFCoordinatorV2.sol/MockVRFCoordinatorV2.json +2 -2
- package/dist/artifacts/mocks/core/tokens/crvUSDToken.sol/crvUSDToken.json +2 -2
- package/dist/artifacts/zap/AladdinZap.sol/AladdinZap.json +398 -0
- package/dist/artifacts/zeno/Auction.sol/Auction.json +2 -2
- package/dist/artifacts/zeno/AuctionFactory.sol/AuctionFactory.json +2 -2
- package/dist/artifacts/zeno/Zeno.sol/Zeno.json +2 -2
- package/dist/artifacts/zeno/ZenoFactory.sol/ZenoFactory.json +2 -2
- package/dist/configs/chains/11155111.json +72 -16
- package/dist/configs/chains/8453.json +40 -8
- package/dist/contracts/getContractAddress.js +3 -0
- package/dist/contracts/governance/distributor/claimAll.js +25 -0
- package/dist/contracts/governance/distributor/claimForGauge.js +26 -0
- package/dist/contracts/governance/distributor/deposit.js +12 -21
- package/dist/contracts/governance/distributor/getClaimableForGauge.js +29 -0
- package/dist/contracts/governance/distributor/getClaimedAtEpoch.js +30 -0
- package/dist/contracts/governance/distributor/getDepositedAtEpoch.js +30 -0
- package/dist/contracts/governance/distributor/getGaugeController.js +28 -0
- package/dist/contracts/governance/distributor/getLastClaimedEpoch.js +29 -0
- package/dist/contracts/governance/distributor/getPeriodDuration.js +28 -0
- package/dist/contracts/governance/distributor/{getRewardTokens.js → getRewardToken.js} +10 -9
- package/dist/contracts/governance/distributor/getRewardTokenInfo.js +9 -19
- package/dist/contracts/governance/distributor/getRewardTokenStats.js +30 -0
- package/dist/contracts/governance/{gaugeController/isGauge.js → distributor/getStartEpoch.js} +10 -10
- package/dist/contracts/governance/distributor/index.js +31 -17
- package/dist/contracts/governance/distributor/setController.js +26 -0
- package/dist/contracts/governance/distributor/withdrawRemovedGaugeRewards.js +27 -0
- package/dist/contracts/governance/distributor/withdrawUnallocatedRewards.js +26 -0
- package/dist/contracts/governance/gauge/addRewardToken.js +34 -0
- package/dist/contracts/governance/gauge/claimExtraReward.js +34 -0
- package/dist/contracts/governance/gauge/claimExtraRewards.js +33 -0
- package/dist/contracts/governance/gauge/claimOnBehalfOf.js +36 -0
- package/dist/contracts/governance/gauge/claimRewardToken.js +3 -4
- package/dist/contracts/governance/gauge/claimRewardsFor.js +34 -0
- package/dist/contracts/governance/gauge/depositRewardToken.js +35 -0
- package/dist/contracts/governance/gauge/getAllPendingExtraRewards.js +36 -0
- package/dist/contracts/governance/gauge/getControllerAddress.js +34 -0
- package/dist/contracts/governance/gauge/getDecimalAdjustment.js +35 -0
- package/dist/contracts/governance/gauge/getDepositRAACOnClaim.js +34 -0
- package/dist/contracts/governance/gauge/getDistributorData.js +36 -0
- package/dist/contracts/governance/gauge/getDistributors.js +34 -0
- package/dist/contracts/governance/gauge/getEarnedReward.js +11 -19
- package/dist/contracts/governance/gauge/getExtraRewardTokens.js +34 -0
- package/dist/contracts/governance/gauge/getGaugeRewardTokenData.js +44 -0
- package/dist/contracts/governance/gauge/getPendingExtraRewards.js +36 -0
- package/dist/contracts/governance/gauge/getPendingRewards.js +11 -19
- package/dist/contracts/governance/gauge/getRaacAutolockMin.js +34 -0
- package/dist/contracts/governance/gauge/getUserRewardTokenData.js +37 -0
- package/dist/contracts/governance/gauge/getUserWeight.js +35 -0
- package/dist/contracts/governance/gauge/index.js +53 -35
- package/dist/contracts/governance/gauge/isPaused.js +34 -0
- package/dist/contracts/governance/gauge/manageDistributor.js +35 -0
- package/dist/contracts/governance/gauge/setController.js +34 -0
- package/dist/contracts/governance/gauge/setDepositRAACOnClaim.js +34 -0
- package/dist/contracts/governance/gauge/setDistributorApproval.js +35 -0
- package/dist/contracts/governance/gauge/setEmergencyPaused.js +34 -0
- package/dist/contracts/governance/gauge/setGaugeRewardDistributor.js +34 -0
- package/dist/contracts/governance/gauge/setRaacAutolockMin.js +34 -0
- package/dist/contracts/governance/gauge/updateUserRewards.js +3 -2
- package/dist/contracts/governance/gaugeController/addGauge.js +24 -0
- package/dist/contracts/governance/gaugeController/batchVote.js +25 -0
- package/dist/contracts/governance/gaugeController/forceCompleteCheckpoint.js +24 -0
- package/dist/contracts/governance/gaugeController/getConstants.js +45 -0
- package/dist/contracts/governance/gaugeController/getCurrentEpoch.js +27 -0
- package/dist/contracts/governance/gaugeController/getGauge.js +29 -0
- package/dist/contracts/governance/gaugeController/getGaugeRelativeWeight.js +29 -0
- package/dist/contracts/governance/gaugeController/getGaugeRelativeWeightView.js +30 -0
- package/dist/contracts/governance/gaugeController/getLastVoteTime.js +29 -0
- package/dist/contracts/governance/gaugeController/getNextEpoch.js +27 -0
- package/dist/contracts/governance/gaugeController/getUserGaugeVotePower.js +29 -0
- package/dist/contracts/governance/gaugeController/getVeToken.js +27 -0
- package/dist/contracts/governance/gaugeController/getVoteUserPower.js +28 -0
- package/dist/contracts/governance/gaugeController/getVoteUserSlope.js +30 -0
- package/dist/contracts/governance/gaugeController/index.js +43 -23
- package/dist/contracts/governance/gaugeController/isPaused.js +27 -0
- package/dist/contracts/governance/gaugeController/kick.js +24 -0
- package/dist/contracts/governance/gaugeController/removeGauge.js +24 -0
- package/dist/contracts/governance/gaugeController/removePowerFromGauge.js +24 -0
- package/dist/contracts/governance/gaugeController/setBoostAmplificationEnabled.js +25 -0
- package/dist/contracts/governance/gaugeController/setEmergencyGaugePause.js +25 -0
- package/dist/contracts/governance/gaugeController/setEmergencyPause.js +24 -0
- package/dist/contracts/lockers/botLocker/_helpers.js +19 -0
- package/dist/contracts/lockers/botLocker/claim.js +16 -0
- package/dist/contracts/lockers/botLocker/getClaimable.js +12 -0
- package/dist/contracts/lockers/botLocker/getClaimables.js +16 -0
- package/dist/contracts/lockers/botLocker/getClaimedRewards.js +13 -0
- package/dist/contracts/lockers/botLocker/getLockedTokenIds.js +10 -0
- package/dist/contracts/lockers/botLocker/getLocks.js +27 -0
- package/dist/contracts/lockers/botLocker/getRewardTokenCount.js +10 -0
- package/dist/contracts/lockers/botLocker/getRewardTokens.js +9 -0
- package/dist/contracts/lockers/botLocker/lock.js +17 -0
- package/dist/contracts/lockers/botLocker/unlock.js +20 -0
- package/dist/contracts/lockers/botLocker/unlockAndClaim.js +16 -0
- package/dist/contracts/lockers/liquidLocker/_helpers.js +19 -0
- package/dist/contracts/lockers/liquidLocker/borrow.js +17 -0
- package/dist/contracts/lockers/liquidLocker/deposit.js +17 -0
- package/dist/contracts/lockers/liquidLocker/donate.js +16 -0
- package/dist/contracts/lockers/liquidLocker/getConfig.js +52 -0
- package/dist/contracts/lockers/liquidLocker/getGlobalInfo.js +39 -0
- package/dist/contracts/lockers/liquidLocker/getUserInfo.js +28 -0
- package/dist/contracts/lockers/liquidLocker/getUserLocks.js +26 -0
- package/dist/contracts/lockers/liquidLocker/harvest.js +17 -0
- package/dist/contracts/lockers/liquidLocker/isKeeper.js +9 -0
- package/dist/contracts/lockers/liquidLocker/processVaultExpiredLocks.js +17 -0
- package/dist/contracts/lockers/liquidLocker/repay.js +17 -0
- package/dist/contracts/lockers/liquidLocker/requestUnlock.js +17 -0
- package/dist/contracts/lockers/liquidLocker/voteGauge.js +17 -0
- package/dist/contracts/lockers/liquidLocker/voteGovernance.js +16 -0
- package/dist/contracts/lockers/liquidLocker/withdrawUnlocked.js +16 -0
- package/dist/contracts/lockers/maturityVault/_helpers.js +19 -0
- package/dist/contracts/lockers/maturityVault/claim.js +16 -0
- package/dist/contracts/lockers/maturityVault/deposit.js +17 -0
- package/dist/contracts/lockers/maturityVault/depositFor.js +16 -0
- package/dist/contracts/lockers/maturityVault/distribute.js +17 -0
- package/dist/contracts/lockers/maturityVault/exit.js +16 -0
- package/dist/contracts/lockers/maturityVault/getConfig.js +26 -0
- package/dist/contracts/lockers/maturityVault/getGlobalInfo.js +45 -0
- package/dist/contracts/lockers/maturityVault/getUserInfo.js +18 -0
- package/dist/contracts/lockers/maturityVault/harvest.js +17 -0
- package/dist/contracts/lockers/maturityVault/isWhitelisted.js +9 -0
- package/dist/contracts/lockers/maturityVault/updatePendingDistribution.js +16 -0
- package/dist/contracts/lockers/maturityVault/withdraw.js +16 -0
- package/dist/contracts/lockers/maturityVault/withdrawAll.js +16 -0
- package/dist/contracts/tokens/leRAAC/_helpers.js +19 -0
- package/dist/contracts/tokens/leRAAC/approve.js +13 -0
- package/dist/contracts/tokens/leRAAC/burn.js +16 -0
- package/dist/contracts/tokens/leRAAC/burnFrom.js +16 -0
- package/dist/contracts/tokens/leRAAC/getAllowance.js +11 -0
- package/dist/contracts/tokens/leRAAC/getBalance.js +11 -0
- package/dist/contracts/tokens/leRAAC/getMinterInfo.js +15 -0
- package/dist/contracts/tokens/leRAAC/getTotalSupply.js +11 -0
- package/dist/contracts/tokens/leRAAC/transfer.js +13 -0
- package/dist/contracts/tokens/leRAAC/transferFrom.js +13 -0
- package/dist/contracts/zap/aladdin/_helpers.js +19 -0
- package/dist/contracts/zap/aladdin/_types.js +38 -0
- package/dist/contracts/zap/aladdin/decodeRoute.js +36 -0
- package/dist/contracts/zap/aladdin/encodeRoute.js +34 -0
- package/dist/contracts/zap/aladdin/getCurvePoolToken.js +13 -0
- package/dist/contracts/zap/aladdin/getOwner.js +9 -0
- package/dist/contracts/zap/aladdin/getPool2Token.js +12 -0
- package/dist/contracts/zap/aladdin/getRoutes.js +16 -0
- package/dist/contracts/zap/aladdin/getVersion.js +9 -0
- package/dist/contracts/zap/aladdin/rescue.js +16 -0
- package/dist/contracts/zap/aladdin/updatePoolTokens.js +19 -0
- package/dist/contracts/zap/aladdin/updateRoute.js +31 -0
- package/dist/contracts/zap/aladdin/validateRoute.js +80 -0
- package/dist/contracts/zap/aladdin/zap.js +18 -0
- package/dist/contracts/zap/aladdin/zapFrom.js +18 -0
- package/dist/contracts/zap/aladdin/zapWithRoutes.js +28 -0
- package/dist/contracts/zap/codec.js +423 -0
- package/dist/minter/_helpers.js +19 -0
- package/dist/minter/activate.js +18 -0
- package/dist/minter/addDistributionPool.js +17 -0
- package/dist/minter/calculateScheduledMintableAmount.js +14 -0
- package/dist/minter/get.js +44 -112
- package/dist/minter/getApy.js +55 -19
- package/dist/minter/getDistributionPools.js +39 -0
- package/dist/minter/getEmissionPerSecond.js +25 -0
- package/dist/minter/getPoolInfo.js +23 -0
- package/dist/minter/isPaused.js +9 -0
- package/dist/minter/manageDistributionPool.js +18 -0
- package/dist/minter/pause.js +24 -0
- package/dist/minter/removeDistributionPool.js +20 -0
- package/dist/minter/tick.js +12 -24
- package/dist/types/RPCLibrary.d.ts +177 -64
- package/dist/types/contracts/governance/distributor/claimAll.d.ts +11 -0
- package/dist/types/contracts/governance/distributor/claimForGauge.d.ts +12 -0
- package/dist/types/contracts/governance/distributor/deposit.d.ts +6 -7
- package/dist/types/contracts/governance/distributor/getClaimableForGauge.d.ts +11 -0
- package/dist/types/contracts/governance/distributor/getClaimedAtEpoch.d.ts +12 -0
- package/dist/types/contracts/governance/distributor/getDepositedAtEpoch.d.ts +12 -0
- package/dist/types/contracts/governance/distributor/getGaugeController.d.ts +10 -0
- package/dist/types/contracts/governance/distributor/getLastClaimedEpoch.d.ts +11 -0
- package/dist/types/contracts/governance/distributor/getPeriodDuration.d.ts +10 -0
- package/dist/types/contracts/governance/distributor/{getRewardTokens.d.ts → getRewardToken.d.ts} +3 -3
- package/dist/types/contracts/governance/distributor/getRewardTokenInfo.d.ts +8 -10
- package/dist/types/contracts/governance/distributor/getRewardTokenStats.d.ts +15 -0
- package/dist/types/contracts/governance/distributor/getStartEpoch.d.ts +10 -0
- package/dist/types/contracts/governance/distributor/index.d.ts +16 -8
- package/dist/types/contracts/governance/distributor/setController.d.ts +12 -0
- package/dist/types/contracts/governance/distributor/withdrawRemovedGaugeRewards.d.ts +13 -0
- package/dist/types/contracts/governance/distributor/withdrawUnallocatedRewards.d.ts +12 -0
- package/dist/types/contracts/governance/gauge/addRewardToken.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/claimExtraReward.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/claimExtraRewards.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/claimOnBehalfOf.d.ts +12 -0
- package/dist/types/contracts/governance/gauge/claimRewardToken.d.ts +1 -2
- package/dist/types/contracts/governance/gauge/claimRewardsFor.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/depositRewardToken.d.ts +11 -0
- package/dist/types/contracts/governance/gauge/getAllPendingExtraRewards.d.ts +13 -0
- package/dist/types/contracts/governance/gauge/getControllerAddress.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/getDecimalAdjustment.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/getDepositRAACOnClaim.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/getDistributorData.d.ts +13 -0
- package/dist/types/contracts/governance/gauge/{getRewardTokens.d.ts → getDistributors.d.ts} +3 -5
- package/dist/types/contracts/governance/gauge/getEarnedReward.d.ts +4 -5
- package/dist/types/contracts/governance/gauge/getExtraRewardTokens.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/getGaugeRewardTokenData.d.ts +18 -0
- package/dist/types/contracts/governance/gauge/getPendingExtraRewards.d.ts +11 -0
- package/dist/types/contracts/governance/gauge/getPendingRewards.d.ts +4 -5
- package/dist/types/contracts/governance/gauge/getRaacAutolockMin.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/getUserRewardTokenData.d.ts +17 -0
- package/dist/types/contracts/governance/gauge/getUserWeight.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/index.d.ts +38 -17
- package/dist/types/contracts/governance/gauge/isPaused.d.ts +9 -0
- package/dist/types/contracts/governance/gauge/manageDistributor.d.ts +11 -0
- package/dist/types/contracts/governance/gauge/setController.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/setDepositRAACOnClaim.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/setDistributorApproval.d.ts +11 -0
- package/dist/types/contracts/governance/gauge/setEmergencyPaused.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/setGaugeRewardDistributor.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/setRaacAutolockMin.d.ts +10 -0
- package/dist/types/contracts/governance/gauge/updateUserRewards.d.ts +2 -1
- package/dist/types/contracts/governance/gaugeController/addGauge.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/batchVote.d.ts +11 -0
- package/dist/types/contracts/governance/gaugeController/forceCompleteCheckpoint.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/getConstants.d.ts +18 -0
- package/dist/types/contracts/governance/gaugeController/getCurrentEpoch.d.ts +9 -0
- package/dist/types/contracts/governance/gaugeController/getGauge.d.ts +15 -0
- package/dist/types/contracts/governance/gaugeController/getGaugeRelativeWeight.d.ts +15 -0
- package/dist/types/contracts/governance/gaugeController/getGaugeRelativeWeightView.d.ts +14 -0
- package/dist/types/contracts/governance/gaugeController/getLastVoteTime.d.ts +11 -0
- package/dist/types/contracts/governance/gaugeController/getNextEpoch.d.ts +9 -0
- package/dist/types/contracts/governance/gaugeController/getUserGaugeVotePower.d.ts +11 -0
- package/dist/types/contracts/governance/gaugeController/getVeToken.d.ts +9 -0
- package/dist/types/contracts/governance/gaugeController/getVoteUserPower.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/getVoteUserSlope.d.ts +15 -0
- package/dist/types/contracts/governance/gaugeController/index.d.ts +28 -11
- package/dist/types/contracts/governance/gaugeController/isPaused.d.ts +9 -0
- package/dist/types/contracts/governance/gaugeController/kick.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/removeGauge.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/removePowerFromGauge.d.ts +10 -0
- package/dist/types/contracts/governance/gaugeController/setBoostAmplificationEnabled.d.ts +11 -0
- package/dist/types/contracts/governance/gaugeController/setEmergencyGaugePause.d.ts +11 -0
- package/dist/types/contracts/governance/gaugeController/setEmergencyPause.d.ts +10 -0
- package/dist/types/contracts/lockers/botLocker/_helpers.d.ts +4 -0
- package/dist/types/contracts/lockers/botLocker/claim.d.ts +6 -0
- package/dist/types/contracts/lockers/botLocker/getClaimable.d.ts +6 -0
- package/dist/types/contracts/lockers/botLocker/getClaimables.d.ts +10 -0
- package/dist/types/contracts/lockers/botLocker/getClaimedRewards.d.ts +7 -0
- package/dist/types/contracts/lockers/botLocker/getLockedTokenIds.d.ts +3 -0
- package/dist/types/contracts/lockers/botLocker/getLocks.d.ts +15 -0
- package/dist/types/contracts/lockers/botLocker/getRewardTokenCount.d.ts +3 -0
- package/dist/types/contracts/lockers/botLocker/getRewardTokens.d.ts +3 -0
- package/dist/types/contracts/lockers/botLocker/lock.d.ts +7 -0
- package/dist/types/contracts/lockers/botLocker/unlock.d.ts +10 -0
- package/dist/types/contracts/lockers/botLocker/unlockAndClaim.d.ts +6 -0
- package/dist/types/contracts/lockers/liquidLocker/_helpers.d.ts +4 -0
- package/dist/types/contracts/lockers/liquidLocker/borrow.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/deposit.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/donate.d.ts +6 -0
- package/dist/types/contracts/lockers/liquidLocker/getConfig.d.ts +27 -0
- package/dist/types/contracts/lockers/liquidLocker/getGlobalInfo.d.ts +24 -0
- package/dist/types/contracts/lockers/liquidLocker/getUserInfo.d.ts +21 -0
- package/dist/types/contracts/lockers/liquidLocker/getUserLocks.d.ts +17 -0
- package/dist/types/contracts/lockers/liquidLocker/harvest.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/isKeeper.d.ts +3 -0
- package/dist/types/contracts/lockers/liquidLocker/processVaultExpiredLocks.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/repay.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/requestUnlock.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/voteGauge.d.ts +7 -0
- package/dist/types/contracts/lockers/liquidLocker/voteGovernance.d.ts +6 -0
- package/dist/types/contracts/lockers/liquidLocker/withdrawUnlocked.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/_helpers.d.ts +4 -0
- package/dist/types/contracts/lockers/maturityVault/claim.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/deposit.d.ts +7 -0
- package/dist/types/contracts/lockers/maturityVault/depositFor.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/distribute.d.ts +7 -0
- package/dist/types/contracts/lockers/maturityVault/exit.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/getConfig.d.ts +12 -0
- package/dist/types/contracts/lockers/maturityVault/getGlobalInfo.d.ts +32 -0
- package/dist/types/contracts/lockers/maturityVault/getUserInfo.d.ts +14 -0
- package/dist/types/contracts/lockers/maturityVault/harvest.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/isWhitelisted.d.ts +3 -0
- package/dist/types/contracts/lockers/maturityVault/updatePendingDistribution.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/withdraw.d.ts +6 -0
- package/dist/types/contracts/lockers/maturityVault/withdrawAll.d.ts +6 -0
- package/dist/types/contracts/tokens/leRAAC/_helpers.d.ts +4 -0
- package/dist/types/contracts/tokens/leRAAC/approve.d.ts +3 -0
- package/dist/types/contracts/tokens/leRAAC/burn.d.ts +6 -0
- package/dist/types/contracts/tokens/leRAAC/burnFrom.d.ts +6 -0
- package/dist/types/contracts/tokens/leRAAC/getAllowance.d.ts +3 -0
- package/dist/types/contracts/tokens/leRAAC/getBalance.d.ts +3 -0
- package/dist/types/contracts/tokens/leRAAC/getMinterInfo.d.ts +8 -0
- package/dist/types/contracts/tokens/leRAAC/getTotalSupply.d.ts +3 -0
- package/dist/types/contracts/tokens/leRAAC/transfer.d.ts +3 -0
- package/dist/types/contracts/tokens/leRAAC/transferFrom.d.ts +3 -0
- package/dist/types/contracts/zap/aladdin/_helpers.d.ts +4 -0
- package/dist/types/contracts/zap/aladdin/_types.d.ts +44 -0
- package/dist/types/contracts/zap/aladdin/decodeRoute.d.ts +14 -0
- package/dist/types/contracts/zap/aladdin/encodeRoute.d.ts +18 -0
- package/dist/types/contracts/zap/aladdin/getCurvePoolToken.d.ts +8 -0
- package/dist/types/contracts/zap/aladdin/getOwner.d.ts +3 -0
- package/dist/types/contracts/zap/aladdin/getPool2Token.d.ts +6 -0
- package/dist/types/contracts/zap/aladdin/getRoutes.d.ts +13 -0
- package/dist/types/contracts/zap/aladdin/getVersion.d.ts +3 -0
- package/dist/types/contracts/zap/aladdin/rescue.d.ts +6 -0
- package/dist/types/contracts/zap/aladdin/updatePoolTokens.d.ts +6 -0
- package/dist/types/contracts/zap/aladdin/updateRoute.d.ts +13 -0
- package/dist/types/contracts/zap/aladdin/validateRoute.d.ts +26 -0
- package/dist/types/contracts/zap/aladdin/zap.d.ts +8 -0
- package/dist/types/contracts/zap/aladdin/zapFrom.d.ts +8 -0
- package/dist/types/contracts/zap/aladdin/zapWithRoutes.d.ts +11 -0
- package/dist/types/contracts/zap/codec.d.ts +36 -0
- package/dist/types/minter/_helpers.d.ts +4 -0
- package/dist/types/minter/activate.d.ts +8 -0
- package/dist/types/minter/addDistributionPool.d.ts +7 -0
- package/dist/types/minter/calculateScheduledMintableAmount.d.ts +8 -0
- package/dist/types/minter/get.d.ts +28 -16
- package/dist/types/minter/getApy.d.ts +19 -2
- package/dist/types/minter/getDistributionPools.d.ts +16 -0
- package/dist/types/minter/getEmissionPerSecond.d.ts +8 -0
- package/dist/types/minter/getPoolInfo.d.ts +13 -0
- package/dist/types/minter/isPaused.d.ts +3 -0
- package/dist/types/minter/manageDistributionPool.d.ts +8 -0
- package/dist/types/minter/pause.d.ts +6 -0
- package/dist/types/minter/removeDistributionPool.d.ts +10 -0
- package/dist/types/minter/tick.d.ts +7 -3
- package/dist/types/typechain-types/@openzeppelin/{contracts-v3/token/ERC20/IERC20.d.ts → contracts/token/ERC20/extensions/ERC20Capped.d.ts} +34 -18
- package/dist/types/typechain-types/@openzeppelin/contracts/token/ERC20/extensions/index.d.ts +1 -0
- package/dist/types/typechain-types/@openzeppelin/contracts-upgradeable/index.d.ts +2 -0
- package/dist/types/typechain-types/@openzeppelin/contracts-upgradeable/token/ERC20/ERC20Upgradeable.d.ts +155 -0
- package/dist/types/typechain-types/@openzeppelin/contracts-upgradeable/token/ERC20/index.d.ts +1 -0
- package/dist/types/typechain-types/@openzeppelin/index.d.ts +0 -2
- package/dist/types/typechain-types/contracts/core/collectors/NFTRoyaltyFeeCollector.sol/NFTRoyaltyFeeCollector.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/governance/gauges/BaseGauge.d.ts +1 -25
- package/dist/types/typechain-types/contracts/core/governance/gauges/GaugeController.d.ts +1 -13
- package/dist/types/typechain-types/contracts/core/governance/gauges/RAACGauge.d.ts +1 -25
- package/dist/types/typechain-types/contracts/core/governance/gauges/RWAGauge.d.ts +1 -25
- package/dist/types/typechain-types/contracts/core/lockers/RAACLiquidLocker.d.ts +101 -171
- package/dist/types/typechain-types/contracts/core/lockers/RAACMaturityVault.d.ts +5 -38
- package/dist/types/typechain-types/contracts/core/minters/RAACMinter/RAACMinter.d.ts +58 -418
- package/dist/types/typechain-types/contracts/core/oracles/BaseVRFv2Consumer.d.ts +108 -2
- package/dist/types/typechain-types/contracts/core/oracles/KYCVerifyModule.sol/IKYCVerifyModule.d.ts +25 -0
- package/dist/types/typechain-types/{@openzeppelin/contracts-v3/access/Ownable.d.ts → contracts/core/oracles/KYCVerifyModule.sol/KYCVerifyModule.d.ts} +10 -6
- package/dist/types/typechain-types/contracts/core/oracles/KYCVerifyModule.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/core/oracles/PmUSDToUSDOracle.d.ts +338 -0
- package/dist/types/typechain-types/contracts/core/oracles/RWAIndexTokenOracle.sol/RWAIndexTokenOracle.d.ts +60 -4
- package/dist/types/typechain-types/contracts/core/oracles/ZkMeKYCVerifyModule.sol/ZKMEKYCVerifyModule.d.ts +110 -0
- package/dist/types/typechain-types/contracts/core/oracles/ZkMeKYCVerifyModule.sol/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/core/oracles/index.d.ts +5 -0
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/ERC20AssetAdapter.sol/ERC20AssetAdapter.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/ERC721AssetAdapter.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/LendingPool.d.ts +9 -23
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/LendingPoolStorage.d.ts +8 -4
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/LiquidationProxy.d.ts +8 -4
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/VaultProxy.d.ts +8 -4
- package/dist/types/typechain-types/contracts/core/pools/StabilityPool/LiquidationSwap.d.ts +70 -1
- package/dist/types/typechain-types/contracts/core/tokens/DEToken.d.ts +16 -1
- package/dist/types/typechain-types/contracts/core/tokens/LeRAAC.sol/LiquidEscrowedRAAC.d.ts +3 -3
- package/dist/types/typechain-types/contracts/core/tokens/RAACNFT.d.ts +65 -50
- package/dist/types/typechain-types/contracts/core/tokens/RAACToken.d.ts +6 -191
- package/dist/types/typechain-types/contracts/core/tokens/RWAIndexToken.d.ts +62 -1
- package/dist/types/typechain-types/contracts/core/tokens/SToken.d.ts +804 -0
- package/dist/types/typechain-types/contracts/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/core/vaults/ERC20VaultAdapter.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/vaults/ERC721VaultAdapter.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/vaults/RAACNFTVaultAdapterV2.d.ts +15 -1
- package/dist/types/typechain-types/contracts/core/vaults/RWAVault.d.ts +28 -2
- package/dist/types/typechain-types/contracts/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/interfaces/IZap.d.ts +15 -1
- package/dist/types/typechain-types/contracts/interfaces/core/governance/gauges/IBaseGauge.d.ts +1 -25
- package/dist/types/typechain-types/contracts/interfaces/core/lockers/IRaacLiquidLocker.d.ts +30 -37
- package/dist/types/typechain-types/contracts/interfaces/core/minters/RAACMinter/IRAACMinter.d.ts +68 -205
- package/dist/types/typechain-types/contracts/interfaces/core/oracles/IBaseVRFv2Consumer.d.ts +100 -2
- package/dist/types/typechain-types/contracts/interfaces/core/oracles/IZKMEVerifyUpgradeable.d.ts +15 -1
- package/dist/types/typechain-types/contracts/interfaces/core/pools/LendingPool/ILendingPool.d.ts +1 -19
- package/dist/types/typechain-types/contracts/interfaces/core/pools/StabilityPool/ILiquidationSwap.d.ts +70 -1
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IDEToken.d.ts +16 -1
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IRAACNFT.d.ts +36 -25
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IRAACToken.d.ts +2 -179
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/ISToken.d.ts +454 -0
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/interfaces/core/vaults/IBaseHybridVault.d.ts +15 -1
- package/dist/types/typechain-types/contracts/interfaces/core/vaults/IVaultAssetAdapter.d.ts +19 -3
- package/dist/types/typechain-types/contracts/interfaces/curve/ICurveCrvUSDVault.d.ts +47 -1
- package/dist/types/typechain-types/contracts/mocks/core/curve/CurveCrvUSDVaultMock.d.ts +47 -1
- package/dist/types/typechain-types/contracts/mocks/core/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/mocks/core/minters/MockRAACMinterRewardsReceiver.d.ts +181 -0
- package/dist/types/typechain-types/contracts/mocks/core/minters/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/core/oracles/MockZKMEVerifyUpgradeable.d.ts +15 -1
- package/dist/types/typechain-types/contracts/mocks/core/pools/MockLendingPoolDebtToken.d.ts +1 -19
- package/dist/types/typechain-types/contracts/mocks/core/tokens/MockFeeOnTransferToken.d.ts +163 -0
- package/dist/types/typechain-types/contracts/mocks/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/libraries/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/mocks/libraries/minters/EmissionScheduleMock.d.ts +91 -0
- package/dist/types/typechain-types/contracts/mocks/libraries/minters/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/rwaf/ChainlinkOracleAdapter.sol/ChainlinkOracleAdapter.d.ts +212 -0
- package/dist/types/typechain-types/contracts/rwaf/ChainlinkOracleAdapter.sol/IRWACoordinator.d.ts +67 -0
- package/dist/types/typechain-types/contracts/rwaf/ChainlinkOracleAdapter.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/rwaf/TokenBlender.sol/ITokenBlender.d.ts +331 -0
- package/dist/types/typechain-types/contracts/rwaf/TokenBlender.sol/TokenBlender.d.ts +671 -0
- package/dist/types/typechain-types/contracts/rwaf/TokenBlender.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/rwaf/index.d.ts +4 -0
- package/dist/types/typechain-types/contracts/zap/AladdinZap.d.ts +15 -1
- package/dist/types/typechain-types/contracts/zap/index.d.ts +0 -2
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/functions/v1_0_0/libraries/FunctionsRequest__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/shared/access/ConfirmedOwnerWithProposal__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/shared/access/ConfirmedOwner__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/dev/libraries/VRFV2PlusClient__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/mocks/VRFCoordinatorV2_5Mock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/token/ERC20/extensions/ERC20Capped__factory.d.ts +271 -0
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/token/ERC20/extensions/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/token/ERC20/utils/SafeERC20__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/Address__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/Errors__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/ShortStrings__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/Strings__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/cryptography/ECDSA__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/cryptography/MerkleProof__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts/utils/math/SafeCast__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts-upgradeable/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/@openzeppelin/{contracts-v3/token/ERC20/IERC20__factory.d.ts → contracts-upgradeable/token/ERC20/ERC20Upgradeable__factory.d.ts} +122 -10
- package/dist/types/typechain-types/factories/@openzeppelin/contracts-upgradeable/token/ERC20/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/@openzeppelin/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/ERC20Collector__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/FeeCollector__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/NFTRoyaltyFeeCollector.sol/NFTRoyaltyFeeCollector__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/RAACTokenCollector__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/RWAIndexTokenCollector__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/collectors/Treasury__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/BaseGauge__factory.d.ts +0 -20
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/GaugeController__factory.d.ts +1 -17
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/GaugeRewardsDistributor__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/RAACGauge__factory.d.ts +1 -21
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/RWAGauge__factory.d.ts +1 -21
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/VeBoostProxy__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/governance/gauges/VeBoost__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/governance/proposals/Governance__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/governance/proposals/TimelockController__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/lockers/RAACBotLocker__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/lockers/RAACLiquidLocker__factory.d.ts +129 -197
- package/dist/types/typechain-types/factories/contracts/core/lockers/RAACMaturityVault__factory.d.ts +11 -51
- package/dist/types/typechain-types/factories/contracts/core/lockers/RAACNFTLocker__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/minters/RAACMinter/RAACMinter__factory.d.ts +28 -557
- package/dist/types/typechain-types/factories/contracts/core/minters/RAACReleaseOrchestrator/RAACReleaseOrchestrator__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/BaseVRFv2Consumer__factory.d.ts +81 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/CrvUSDToUSDOracle.sol/CrvUSDToUSDOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/KYCVerifyModule.sol/IKYCVerifyModule__factory.d.ts +25 -0
- package/dist/types/typechain-types/factories/{@openzeppelin/contracts-v3/access/Ownable__factory.d.ts → contracts/core/oracles/KYCVerifyModule.sol/KYCVerifyModule__factory.d.ts} +38 -4
- package/dist/types/typechain-types/factories/contracts/core/oracles/KYCVerifyModule.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/contracts/core/oracles/PmUSDToUSDOracle__factory.d.ts +443 -0
- package/dist/types/typechain-types/factories/contracts/core/oracles/RAACHousePriceOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/RAACPrimeRateOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/RWAIndexTokenOracle.sol/RWAIndexTokenOracle__factory.d.ts +97 -3
- package/dist/types/typechain-types/factories/contracts/core/oracles/ZkMeKYCVerifyModule.sol/ZKMEKYCVerifyModule__factory.d.ts +181 -0
- package/dist/types/typechain-types/factories/contracts/core/oracles/ZkMeKYCVerifyModule.sol/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/core/oracles/crvUSDPriceOracle.sol/CrvUSDPriceOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/oracles/index.d.ts +3 -0
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/ERC20AssetAdapter.sol/ERC20AssetAdapter__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/ERC721AssetAdapter__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/LendingPoolStorage__factory.d.ts +9 -5
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/LendingPool__factory.d.ts +9 -31
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/LiquidationProxy__factory.d.ts +9 -5
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/VaultProxy__factory.d.ts +9 -5
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/LiquidationStrategyProxy__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/LiquidationSwap__factory.d.ts +62 -3
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/StabilityPoolStorage__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/StabilityPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/primitives/ComplianceRegistry.sol/ComplianceRegistry__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/primitives/RAACHousePrices__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/DEToken__factory.d.ts +16 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/DebtToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/LPToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/LeRAAC.sol/LiquidEscrowedRAAC__factory.d.ts +7 -3
- package/dist/types/typechain-types/factories/contracts/core/tokens/RAACNFT__factory.d.ts +79 -58
- package/dist/types/typechain-types/factories/contracts/core/tokens/RAACToken__factory.d.ts +21 -252
- package/dist/types/typechain-types/factories/contracts/core/tokens/RToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/RWAIndexToken__factory.d.ts +51 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/SToken__factory.d.ts +1153 -0
- package/dist/types/typechain-types/factories/contracts/core/tokens/VeRAACToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/core/vaults/ERC20VaultAdapter__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/vaults/ERC721VaultAdapter__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/vaults/RAACNFTVaultAdapterOracle.sol/RAACNFTVaultAdapterOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/vaults/RAACNFTVaultAdapterV2__factory.d.ts +11 -1
- package/dist/types/typechain-types/factories/contracts/core/vaults/RWAVault__factory.d.ts +35 -1
- package/dist/types/typechain-types/factories/contracts/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/IZap__factory.d.ts +18 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/governance/gauges/IBaseGauge__factory.d.ts +0 -20
- package/dist/types/typechain-types/factories/contracts/interfaces/core/lockers/IRaacLiquidLocker__factory.d.ts +26 -29
- package/dist/types/typechain-types/factories/contracts/interfaces/core/minters/RAACMinter/IRAACMinter__factory.d.ts +44 -230
- package/dist/types/typechain-types/factories/contracts/interfaces/core/oracles/IBaseVRFv2Consumer__factory.d.ts +70 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/oracles/IZKMEVerifyUpgradeable__factory.d.ts +18 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/pools/LendingPool/ILendingPool__factory.d.ts +0 -26
- package/dist/types/typechain-types/factories/contracts/interfaces/core/pools/StabilityPool/ILiquidationSwap__factory.d.ts +55 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IDEToken__factory.d.ts +15 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IRAACNFT__factory.d.ts +28 -15
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IRAACToken__factory.d.ts +0 -219
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/ISToken__factory.d.ts +564 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/vaults/IBaseHybridVault__factory.d.ts +10 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/vaults/IVaultAssetAdapter__factory.d.ts +10 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/curve/ICurveCrvUSDVault__factory.d.ts +66 -0
- package/dist/types/typechain-types/factories/contracts/libraries/governance/BoostCalculator__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/governance/LockManager__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/governance/PowerCheckpoint__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/governance/RagequitLib__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/governance/RewardLib__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/math/TimeWeightedAverage__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/pools/LendingPoolFeeLibrary__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/pools/ReserveLibrary__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/libraries/utils/StringUtils__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/ERC20BurnableMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/collectors/MockTreasury__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/collectors/MockWETH__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/curve/CurveCrvUSDVaultMock__factory.d.ts +67 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/curve/CurveLiquidityGaugeV5Mock.sol/CurveLiquidityGaugeV5Mock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/gauges/MockGaugeController__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/libraries/LockManagerMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/proposals/TimelockPayableTestTarget__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/proposals/TimelockTestTarget__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/lockers/LLamaLocker.sol/LlamaLocker__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/lockers/MockLamaLocker__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/minters/MockRAACMinterRewardsReceiver__factory.d.ts +184 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/minters/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockChainlinkAggregator__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockCurveEMA.sol/MockCurveEMA__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockERC20PriceOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockFunctionsRouter.sol/MockFunctionsRouter__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockRAACNFTVaultAdapterNAVOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockVRFCoordinatorV2__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/MockZKMEVerifyUpgradeable__factory.d.ts +19 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/TestRAACHousePriceOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/oracles/TestRAACPrimeRateOracle__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/CurveStyleCrvUSDiRAACPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLendingPoolCollector__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLendingPoolDebtToken__factory.d.ts +1 -27
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLendingPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLiquidityPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockStabilityPool__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/MockChainAnalysis.sol/MockChainAnalysis__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/MockContractWithConfig__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/MockContract__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/MockDistributableContract__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/RAACHousePricesMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/CrvUSDTokenLimited__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/CrvUSDToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/ERC20Mock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/ERC721Mock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockCollectableUnderlying__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockFeeCollectorToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockFeeOnTransferToken__factory.d.ts +306 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockUSDC__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/RAACMockERC20__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/vaults/MockVault__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/MockStringUtils__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/MockTimeUtils__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/governance/BoostCalculatorMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/governance/PowerCheckpointMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/governance/RagequitHarness__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/governance/RewardIntegralCalculatorMock.sol/MockRewardIntegralCalculator__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/math/TimeWeightedAverageMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/math/WadRayMathMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/minters/EmissionScheduleMock__factory.d.ts +115 -0
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/minters/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/pools/ReserveLibraryMockCalculation__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/pools/ReserveLibraryMock__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/tests/MaliciousDeposit__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/tests/MaliciousWithdraw__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/tests/VeRAACFuzzHelper__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/rwaf/ChainlinkOracleAdapter.sol/ChainlinkOracleAdapter__factory.d.ts +295 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/ChainlinkOracleAdapter.sol/IRWACoordinator__factory.d.ts +43 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/ChainlinkOracleAdapter.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/TokenBlender.sol/ITokenBlender__factory.d.ts +409 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/TokenBlender.sol/TokenBlender__factory.d.ts +990 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/TokenBlender.sol/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/contracts/rwaf/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/contracts/zap/AladdinZap__factory.d.ts +19 -1
- package/dist/types/typechain-types/factories/contracts/zap/index.d.ts +0 -2
- package/dist/types/typechain-types/factories/contracts/zeno/AuctionFactory__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/zeno/Auction__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/zeno/ZENOFactory__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/zeno/ZENO__factory.d.ts +1 -1
- package/dist/types/typechain-types/index.d.ts +34 -8
- package/dist/types/utils/artifacts.d.ts +616 -95
- package/dist/utils/artifacts.js +16 -0
- package/dist/utils/contracts.js +1 -1
- package/package.json +1 -1
- package/dist/contracts/governance/distributor/getAvailableBalance.js +0 -29
- package/dist/contracts/governance/distributor/getGaugeRewardTokens.js +0 -28
- package/dist/contracts/governance/distributor/getTransferableBalance.js +0 -30
- package/dist/contracts/governance/distributor/isRewardTokenApproved.js +0 -29
- package/dist/contracts/governance/distributor/isTokenApproved.js +0 -29
- package/dist/contracts/governance/gauge/claimReward.js +0 -44
- package/dist/contracts/governance/gauge/getAllEarnedRewards.js +0 -51
- package/dist/contracts/governance/gauge/getAllPendingRewards.js +0 -41
- package/dist/contracts/governance/gauge/getRewardTokens.js +0 -41
- package/dist/contracts/governance/gauge/getUserGaugeVoteWeight.js +0 -42
- package/dist/contracts/governance/gauge/getWorkingBalance.js +0 -43
- package/dist/contracts/governance/gauge/syncRewardTokens.js +0 -51
- package/dist/contracts/governance/gaugeController/checkpoint.js +0 -33
- package/dist/contracts/governance/gaugeController/checkpointGauge.js +0 -34
- package/dist/contracts/governance/gaugeController/getUserGaugeVoteWeight.js +0 -30
- package/dist/tests/test.js +0 -32
- package/dist/types/contracts/governance/distributor/getAvailableBalance.d.ts +0 -11
- package/dist/types/contracts/governance/distributor/getGaugeRewardTokens.d.ts +0 -11
- package/dist/types/contracts/governance/distributor/getTransferableBalance.d.ts +0 -12
- package/dist/types/contracts/governance/distributor/isRewardTokenApproved.d.ts +0 -12
- package/dist/types/contracts/governance/distributor/isTokenApproved.d.ts +0 -11
- package/dist/types/contracts/governance/gauge/claimReward.d.ts +0 -11
- package/dist/types/contracts/governance/gauge/getAllEarnedRewards.d.ts +0 -17
- package/dist/types/contracts/governance/gauge/getAllPendingRewards.d.ts +0 -19
- package/dist/types/contracts/governance/gauge/getUserGaugeVoteWeight.d.ts +0 -14
- package/dist/types/contracts/governance/gauge/getWorkingBalance.d.ts +0 -12
- package/dist/types/contracts/governance/gauge/syncRewardTokens.d.ts +0 -13
- package/dist/types/contracts/governance/gaugeController/checkpoint.d.ts +0 -11
- package/dist/types/contracts/governance/gaugeController/checkpointGauge.d.ts +0 -12
- package/dist/types/contracts/governance/gaugeController/getUserGaugeVoteWeight.d.ts +0 -12
- package/dist/types/contracts/governance/gaugeController/isGauge.d.ts +0 -11
- package/dist/types/tests/test.d.ts +0 -1
- package/dist/types/typechain-types/@openzeppelin/contracts-v3/access/index.d.ts +0 -1
- package/dist/types/typechain-types/@openzeppelin/contracts-v3/index.d.ts +0 -4
- package/dist/types/typechain-types/@openzeppelin/contracts-v3/token/ERC20/index.d.ts +0 -1
- package/dist/types/typechain-types/contracts/zap/AladdinCRVZap.d.ts +0 -83
- package/dist/types/typechain-types/contracts/zap/AladdinConvexVaultZap.d.ts +0 -172
- package/dist/types/typechain-types/factories/@openzeppelin/contracts-v3/access/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/@openzeppelin/contracts-v3/index.d.ts +0 -2
- package/dist/types/typechain-types/factories/@openzeppelin/contracts-v3/token/ERC20/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/contracts/zap/AladdinCRVZap__factory.d.ts +0 -107
- package/dist/types/typechain-types/factories/contracts/zap/AladdinConvexVaultZap__factory.d.ts +0 -208
- /package/dist/types/typechain-types/@openzeppelin/{contracts-v3 → contracts-upgradeable}/token/index.d.ts +0 -0
- /package/dist/types/typechain-types/factories/@openzeppelin/{contracts-v3 → contracts-upgradeable}/token/index.d.ts +0 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.setDistributorApproval = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
9
|
+
const getContractAddress_1 = __importDefault(require("../../getContractAddress"));
|
|
10
|
+
/**
|
|
11
|
+
* Sets the approval flag for a distributor on the gauge (requires GAUGE_ADMIN).
|
|
12
|
+
* @param chainId - The chain/network to use.
|
|
13
|
+
* @param gaugeAddressOrId - Address of the gauge contract or its config ID.
|
|
14
|
+
* @param distributor - Address of the distributor.
|
|
15
|
+
* @param isApproved - Whether the distributor should be approved.
|
|
16
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
17
|
+
*/
|
|
18
|
+
const setDistributorApproval = async (chainId, gaugeAddressOrId, distributor, isApproved, signer) => {
|
|
19
|
+
if (!signer)
|
|
20
|
+
throw new Error("Signer is required");
|
|
21
|
+
let gaugeAddress;
|
|
22
|
+
if ((0, ethers_1.isAddress)(gaugeAddressOrId)) {
|
|
23
|
+
gaugeAddress = gaugeAddressOrId;
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
// @ts-ignore
|
|
27
|
+
gaugeAddress = (0, getContractAddress_1.default)(chainId, gaugeAddressOrId.toLowerCase());
|
|
28
|
+
}
|
|
29
|
+
const abi = (0, artifacts_1.getABI)("basegauge");
|
|
30
|
+
const contract = new ethers_1.ethers.Contract(gaugeAddress, abi, signer);
|
|
31
|
+
const tx = await contract.setDistributorApproval(distributor, isApproved);
|
|
32
|
+
await tx.wait();
|
|
33
|
+
return tx;
|
|
34
|
+
};
|
|
35
|
+
exports.setDistributorApproval = setDistributorApproval;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.setEmergencyPaused = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
9
|
+
const getContractAddress_1 = __importDefault(require("../../getContractAddress"));
|
|
10
|
+
/**
|
|
11
|
+
* Sets the emergency paused state of the gauge (requires CONTROLLER_ROLE).
|
|
12
|
+
* @param chainId - The chain/network to use.
|
|
13
|
+
* @param gaugeAddressOrId - Address of the gauge contract or its config ID.
|
|
14
|
+
* @param paused - True to pause, false to unpause.
|
|
15
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
16
|
+
*/
|
|
17
|
+
const setEmergencyPaused = async (chainId, gaugeAddressOrId, paused, signer) => {
|
|
18
|
+
if (!signer)
|
|
19
|
+
throw new Error("Signer is required");
|
|
20
|
+
let gaugeAddress;
|
|
21
|
+
if ((0, ethers_1.isAddress)(gaugeAddressOrId)) {
|
|
22
|
+
gaugeAddress = gaugeAddressOrId;
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
gaugeAddress = (0, getContractAddress_1.default)(chainId, gaugeAddressOrId.toLowerCase());
|
|
27
|
+
}
|
|
28
|
+
const abi = (0, artifacts_1.getABI)("basegauge");
|
|
29
|
+
const contract = new ethers_1.ethers.Contract(gaugeAddress, abi, signer);
|
|
30
|
+
const tx = await contract.setEmergencyPaused(paused);
|
|
31
|
+
await tx.wait();
|
|
32
|
+
return tx;
|
|
33
|
+
};
|
|
34
|
+
exports.setEmergencyPaused = setEmergencyPaused;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.setGaugeRewardDistributor = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
9
|
+
const getContractAddress_1 = __importDefault(require("../../getContractAddress"));
|
|
10
|
+
/**
|
|
11
|
+
* Sets the gauge reward distributor address (requires DEFAULT_ADMIN_ROLE).
|
|
12
|
+
* @param chainId - The chain/network to use.
|
|
13
|
+
* @param gaugeAddressOrId - Address of the gauge contract or its config ID.
|
|
14
|
+
* @param rewardDistributor - Address of the new reward distributor.
|
|
15
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
16
|
+
*/
|
|
17
|
+
const setGaugeRewardDistributor = async (chainId, gaugeAddressOrId, rewardDistributor, signer) => {
|
|
18
|
+
if (!signer)
|
|
19
|
+
throw new Error("Signer is required");
|
|
20
|
+
let gaugeAddress;
|
|
21
|
+
if ((0, ethers_1.isAddress)(gaugeAddressOrId)) {
|
|
22
|
+
gaugeAddress = gaugeAddressOrId;
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
gaugeAddress = (0, getContractAddress_1.default)(chainId, gaugeAddressOrId.toLowerCase());
|
|
27
|
+
}
|
|
28
|
+
const abi = (0, artifacts_1.getABI)("basegauge");
|
|
29
|
+
const contract = new ethers_1.ethers.Contract(gaugeAddress, abi, signer);
|
|
30
|
+
const tx = await contract.setGaugeRewardDistributor(rewardDistributor);
|
|
31
|
+
await tx.wait();
|
|
32
|
+
return tx;
|
|
33
|
+
};
|
|
34
|
+
exports.setGaugeRewardDistributor = setGaugeRewardDistributor;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.setRaacAutolockMin = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
9
|
+
const getContractAddress_1 = __importDefault(require("../../getContractAddress"));
|
|
10
|
+
/**
|
|
11
|
+
* Sets the minimum RAAC amount required to trigger an autolock on claim (requires DEFAULT_ADMIN_ROLE).
|
|
12
|
+
* @param chainId - The chain/network to use.
|
|
13
|
+
* @param gaugeAddressOrId - Address of the gauge contract or its config ID.
|
|
14
|
+
* @param amount - The new minimum autolock amount.
|
|
15
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
16
|
+
*/
|
|
17
|
+
const setRaacAutolockMin = async (chainId, gaugeAddressOrId, amount, signer) => {
|
|
18
|
+
if (!signer)
|
|
19
|
+
throw new Error("Signer is required");
|
|
20
|
+
let gaugeAddress;
|
|
21
|
+
if ((0, ethers_1.isAddress)(gaugeAddressOrId)) {
|
|
22
|
+
gaugeAddress = gaugeAddressOrId;
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
gaugeAddress = (0, getContractAddress_1.default)(chainId, gaugeAddressOrId.toLowerCase());
|
|
27
|
+
}
|
|
28
|
+
const abi = (0, artifacts_1.getABI)("basegauge");
|
|
29
|
+
const contract = new ethers_1.ethers.Contract(gaugeAddress, abi, signer);
|
|
30
|
+
const tx = await contract.setRaacAutolockMin(amount);
|
|
31
|
+
await tx.wait();
|
|
32
|
+
return tx;
|
|
33
|
+
};
|
|
34
|
+
exports.setRaacAutolockMin = setRaacAutolockMin;
|
|
@@ -13,10 +13,11 @@ const getContractAddress_1 = __importDefault(require("../../getContractAddress")
|
|
|
13
13
|
*
|
|
14
14
|
* @param chainId - The chain/network to use.
|
|
15
15
|
* @param gaugeAddressOrId - Address of the gauge contract or ID of the gauge.
|
|
16
|
+
* @param user - Address of the user whose reward state should be settled/kicked.
|
|
16
17
|
* @param signer - An ethers.js Signer instance (must be connected to wallet).
|
|
17
18
|
* @returns Transaction receipt after the update is complete.
|
|
18
19
|
*/
|
|
19
|
-
const updateUserRewards = async (chainId, gaugeAddressOrId, signer) => {
|
|
20
|
+
const updateUserRewards = async (chainId, gaugeAddressOrId, user, signer) => {
|
|
20
21
|
if (!signer) {
|
|
21
22
|
throw new Error("Signer is required");
|
|
22
23
|
}
|
|
@@ -37,7 +38,7 @@ const updateUserRewards = async (chainId, gaugeAddressOrId, signer) => {
|
|
|
37
38
|
try {
|
|
38
39
|
const gaugeABI = (0, artifacts_1.getABI)("basegauge");
|
|
39
40
|
const contract = new ethers_1.ethers.Contract(gaugeAddress, gaugeABI, signer);
|
|
40
|
-
const tx = await contract.updateUserRewards();
|
|
41
|
+
const tx = await contract.updateUserRewards(user);
|
|
41
42
|
await tx.wait();
|
|
42
43
|
console.log(`Updated user rewards for gauge: ${gaugeAddress}`);
|
|
43
44
|
return tx;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.addGauge = void 0;
|
|
4
|
+
const ethers_1 = require("ethers");
|
|
5
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
6
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
7
|
+
/**
|
|
8
|
+
* Adds a new gauge to the GaugeController. Requires the GAUGE_ADMIN role.
|
|
9
|
+
* @param chainId - The chain/network to use.
|
|
10
|
+
* @param gauge - Address of the gauge to add.
|
|
11
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
12
|
+
* @returns The transaction response.
|
|
13
|
+
*/
|
|
14
|
+
const addGauge = async (chainId, gauge, signer) => {
|
|
15
|
+
if (!signer)
|
|
16
|
+
throw new Error("Signer is required");
|
|
17
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
18
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
19
|
+
const contract = new ethers_1.ethers.Contract(address, abi, signer);
|
|
20
|
+
const tx = await contract.addGauge(gauge);
|
|
21
|
+
await tx.wait();
|
|
22
|
+
return tx;
|
|
23
|
+
};
|
|
24
|
+
exports.addGauge = addGauge;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.batchVote = void 0;
|
|
4
|
+
const ethers_1 = require("ethers");
|
|
5
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
6
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
7
|
+
/**
|
|
8
|
+
* Casts votes on multiple gauges in a single transaction.
|
|
9
|
+
* @param chainId - The chain/network to use.
|
|
10
|
+
* @param gaugeAddresses - Array of gauge addresses to vote on.
|
|
11
|
+
* @param voteWeights - Array of vote weights (basis points) aligned with gaugeAddresses.
|
|
12
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
13
|
+
* @returns The transaction response.
|
|
14
|
+
*/
|
|
15
|
+
const batchVote = async (chainId, gaugeAddresses, voteWeights, signer) => {
|
|
16
|
+
if (!signer)
|
|
17
|
+
throw new Error("Signer is required");
|
|
18
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
19
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
20
|
+
const contract = new ethers_1.ethers.Contract(address, abi, signer);
|
|
21
|
+
const tx = await contract.batchVote(gaugeAddresses, voteWeights);
|
|
22
|
+
await tx.wait();
|
|
23
|
+
return tx;
|
|
24
|
+
};
|
|
25
|
+
exports.batchVote = batchVote;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.forceCompleteCheckpoint = void 0;
|
|
4
|
+
const ethers_1 = require("ethers");
|
|
5
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
6
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
7
|
+
/**
|
|
8
|
+
* Forces completion of a pending checkpoint for a gauge.
|
|
9
|
+
* @param chainId - The chain/network to use.
|
|
10
|
+
* @param gauge - Address of the gauge to checkpoint.
|
|
11
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
12
|
+
* @returns The transaction response.
|
|
13
|
+
*/
|
|
14
|
+
const forceCompleteCheckpoint = async (chainId, gauge, signer) => {
|
|
15
|
+
if (!signer)
|
|
16
|
+
throw new Error("Signer is required");
|
|
17
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
18
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
19
|
+
const contract = new ethers_1.ethers.Contract(address, abi, signer);
|
|
20
|
+
const tx = await contract.forceCompleteCheckpoint(gauge);
|
|
21
|
+
await tx.wait();
|
|
22
|
+
return tx;
|
|
23
|
+
};
|
|
24
|
+
exports.forceCompleteCheckpoint = forceCompleteCheckpoint;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getConstants = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Reads the immutable/constant configuration values from the GaugeController.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
15
|
+
* @returns An object with maxBoost, minBoost, weightPrecision, week, weightVoteDelay,
|
|
16
|
+
* minVoteWeight and maxVoteWeight, all bigint.
|
|
17
|
+
*/
|
|
18
|
+
const getConstants = async (chainId, provider) => {
|
|
19
|
+
if (!provider) {
|
|
20
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
21
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
22
|
+
}
|
|
23
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
24
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
25
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
26
|
+
const [maxBoost, minBoost, weightPrecision, week, weightVoteDelay, minVoteWeight, maxVoteWeight,] = await Promise.all([
|
|
27
|
+
contract.MAX_BOOST(),
|
|
28
|
+
contract.MIN_BOOST(),
|
|
29
|
+
contract.WEIGHT_PRECISION(),
|
|
30
|
+
contract.WEEK(),
|
|
31
|
+
contract.WEIGHT_VOTE_DELAY(),
|
|
32
|
+
contract.MIN_VOTE_WEIGHT(),
|
|
33
|
+
contract.MAX_VOTE_WEIGHT(),
|
|
34
|
+
]);
|
|
35
|
+
return {
|
|
36
|
+
maxBoost,
|
|
37
|
+
minBoost,
|
|
38
|
+
weightPrecision,
|
|
39
|
+
week,
|
|
40
|
+
weightVoteDelay,
|
|
41
|
+
minVoteWeight,
|
|
42
|
+
maxVoteWeight,
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
exports.getConstants = getConstants;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getCurrentEpoch = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the current epoch boundary (rounded down to the week) from the GaugeController.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
15
|
+
* @returns Current epoch timestamp as a bigint.
|
|
16
|
+
*/
|
|
17
|
+
const getCurrentEpoch = async (chainId, provider) => {
|
|
18
|
+
if (!provider) {
|
|
19
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
20
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
21
|
+
}
|
|
22
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
23
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
24
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
25
|
+
return contract.getCurrentEpoch();
|
|
26
|
+
};
|
|
27
|
+
exports.getCurrentEpoch = getCurrentEpoch;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getGauge = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Reads the gauge config struct from the public `gauges` mapping on the GaugeController.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param gauge - Address of the gauge.
|
|
15
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
16
|
+
* @returns An object with isActive, isBoostAmplificationEnabled (booleans), weight and lastUpdateTime (bigint).
|
|
17
|
+
*/
|
|
18
|
+
const getGauge = async (chainId, gauge, provider) => {
|
|
19
|
+
if (!provider) {
|
|
20
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
21
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
22
|
+
}
|
|
23
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
24
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
25
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
26
|
+
const [isActive, isBoostAmplificationEnabled, weight, lastUpdateTime] = await contract.gauges(gauge);
|
|
27
|
+
return { isActive, isBoostAmplificationEnabled, weight, lastUpdateTime };
|
|
28
|
+
};
|
|
29
|
+
exports.getGauge = getGauge;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getGaugeRelativeWeight = void 0;
|
|
4
|
+
const ethers_1 = require("ethers");
|
|
5
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
6
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
7
|
+
/**
|
|
8
|
+
* Computes and checkpoints a gauge's relative weight at a given epoch.
|
|
9
|
+
*
|
|
10
|
+
* This is a state-modifying call (it writes checkpoints), so it requires a Signer.
|
|
11
|
+
* For a pure read with no state changes, use getGaugeRelativeWeightView instead.
|
|
12
|
+
*
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param gauge - Address of the gauge.
|
|
15
|
+
* @param epoch - Epoch timestamp to checkpoint.
|
|
16
|
+
* @param signer - An ethers.js Signer instance (required).
|
|
17
|
+
* @returns The transaction response.
|
|
18
|
+
*/
|
|
19
|
+
const getGaugeRelativeWeight = async (chainId, gauge, epoch, signer) => {
|
|
20
|
+
if (!signer)
|
|
21
|
+
throw new Error("Signer is required");
|
|
22
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
23
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
24
|
+
const contract = new ethers_1.ethers.Contract(address, abi, signer);
|
|
25
|
+
const tx = await contract.getGaugeRelativeWeight(gauge, epoch);
|
|
26
|
+
await tx.wait();
|
|
27
|
+
return tx;
|
|
28
|
+
};
|
|
29
|
+
exports.getGaugeRelativeWeight = getGaugeRelativeWeight;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getGaugeRelativeWeightView = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Reads a gauge's relative weight at a given epoch without modifying state.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param gauge - Address of the gauge.
|
|
15
|
+
* @param epoch - Epoch timestamp to query.
|
|
16
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
17
|
+
* @returns An object with relativeWeight (1e18-scaled, where 1e18 = 100%) and totalWeight, both bigint.
|
|
18
|
+
*/
|
|
19
|
+
const getGaugeRelativeWeightView = async (chainId, gauge, epoch, provider) => {
|
|
20
|
+
if (!provider) {
|
|
21
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
22
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
23
|
+
}
|
|
24
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
25
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
26
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
27
|
+
const [relativeWeight, totalWeight] = await contract.getGaugeRelativeWeightView(gauge, epoch);
|
|
28
|
+
return { relativeWeight, totalWeight };
|
|
29
|
+
};
|
|
30
|
+
exports.getGaugeRelativeWeightView = getGaugeRelativeWeightView;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getLastVoteTime = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the timestamp of a user's last vote on a given gauge.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param user - Address of the user.
|
|
15
|
+
* @param gauge - Address of the gauge.
|
|
16
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
17
|
+
* @returns The last vote timestamp as a bigint.
|
|
18
|
+
*/
|
|
19
|
+
const getLastVoteTime = async (chainId, user, gauge, provider) => {
|
|
20
|
+
if (!provider) {
|
|
21
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
22
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
23
|
+
}
|
|
24
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
25
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
26
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
27
|
+
return contract.lastVoteTime(user, gauge);
|
|
28
|
+
};
|
|
29
|
+
exports.getLastVoteTime = getLastVoteTime;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getNextEpoch = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the next epoch boundary (current epoch plus one week) from the GaugeController.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
15
|
+
* @returns Next epoch timestamp as a bigint.
|
|
16
|
+
*/
|
|
17
|
+
const getNextEpoch = async (chainId, provider) => {
|
|
18
|
+
if (!provider) {
|
|
19
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
20
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
21
|
+
}
|
|
22
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
23
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
24
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
25
|
+
return contract.getNextEpoch();
|
|
26
|
+
};
|
|
27
|
+
exports.getNextEpoch = getNextEpoch;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getUserGaugeVotePower = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the vote weight (in basis points) a user has allocated to a gauge.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param user - Address of the user.
|
|
15
|
+
* @param gauge - Address of the gauge.
|
|
16
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
17
|
+
* @returns Vote weight in basis points as a bigint.
|
|
18
|
+
*/
|
|
19
|
+
const getUserGaugeVotePower = async (chainId, user, gauge, provider) => {
|
|
20
|
+
if (!provider) {
|
|
21
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
22
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
23
|
+
}
|
|
24
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
25
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
26
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
27
|
+
return contract.getUserGaugeVotePower(user, gauge);
|
|
28
|
+
};
|
|
29
|
+
exports.getUserGaugeVotePower = getUserGaugeVotePower;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getVeToken = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the veToken (voting escrow token) address used by the GaugeController.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
15
|
+
* @returns The veToken contract address as a string.
|
|
16
|
+
*/
|
|
17
|
+
const getVeToken = async (chainId, provider) => {
|
|
18
|
+
if (!provider) {
|
|
19
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
20
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
21
|
+
}
|
|
22
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
23
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
24
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
25
|
+
return contract.veToken();
|
|
26
|
+
};
|
|
27
|
+
exports.getVeToken = getVeToken;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getVoteUserPower = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Gets the total vote power a user has currently allocated across all gauges.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param user - Address of the user.
|
|
15
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
16
|
+
* @returns The user's allocated vote power as a bigint.
|
|
17
|
+
*/
|
|
18
|
+
const getVoteUserPower = async (chainId, user, provider) => {
|
|
19
|
+
if (!provider) {
|
|
20
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
21
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
22
|
+
}
|
|
23
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
24
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
25
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
26
|
+
return contract.voteUserPower(user);
|
|
27
|
+
};
|
|
28
|
+
exports.getVoteUserPower = getVoteUserPower;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getVoteUserSlope = void 0;
|
|
7
|
+
const ethers_1 = require("ethers");
|
|
8
|
+
const chains_1 = __importDefault(require("../../../configs/chains"));
|
|
9
|
+
const getContractAddress_1 = require("../../getContractAddress");
|
|
10
|
+
const artifacts_1 = require("../../../utils/artifacts");
|
|
11
|
+
/**
|
|
12
|
+
* Reads a user's vote slope for a gauge from the public `voteUserSlopes` mapping.
|
|
13
|
+
* @param chainId - The chain/network to use.
|
|
14
|
+
* @param user - Address of the user.
|
|
15
|
+
* @param gauge - Address of the gauge.
|
|
16
|
+
* @param provider - Optional ethers.js Provider instance.
|
|
17
|
+
* @returns An object with locked, power and end, all bigint.
|
|
18
|
+
*/
|
|
19
|
+
const getVoteUserSlope = async (chainId, user, gauge, provider) => {
|
|
20
|
+
if (!provider) {
|
|
21
|
+
const rpc = chains_1.default[chainId].rpcs[0];
|
|
22
|
+
provider = new ethers_1.ethers.JsonRpcProvider(rpc);
|
|
23
|
+
}
|
|
24
|
+
const address = (0, getContractAddress_1.getContractAddress)(chainId, "gaugecontroller");
|
|
25
|
+
const abi = (0, artifacts_1.getABI)("gaugecontroller");
|
|
26
|
+
const contract = new ethers_1.ethers.Contract(address, abi, provider);
|
|
27
|
+
const [locked, power, end] = await contract.voteUserSlopes(user, gauge);
|
|
28
|
+
return { locked, power, end };
|
|
29
|
+
};
|
|
30
|
+
exports.getVoteUserSlope = getVoteUserSlope;
|