@raac/rpc 1.0.1 → 1.0.2-beta.2
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 +61 -8
- package/dist/artifacts/core/collectors/FeeCollector.sol/FeeCollector.json +1743 -0
- package/dist/artifacts/core/minters/RAACMinter/RAACMinter.sol/RAACMinter.json +175 -67
- package/dist/artifacts/core/oracles/BaseVRFv2Consumer.sol/BaseVRFv2Consumer.json +279 -0
- package/dist/artifacts/core/pools/LendingPool/LendingPool.sol/LendingPool.json +1231 -195
- package/dist/artifacts/core/pools/StabilityPool/StabilityPool.sol/StabilityPool.json +153 -199
- package/dist/artifacts/core/primitives/RAACHousePrices.sol/RAACHousePrices.json +72 -2
- package/dist/artifacts/core/tokens/DEToken.sol/DEToken.json +2 -2
- package/dist/artifacts/core/tokens/IndexToken.sol/IndexToken.json +770 -0
- package/dist/artifacts/core/tokens/RAACNFT.sol/RAACNFT.json +707 -49
- package/dist/artifacts/core/tokens/RAACToken.sol/RAACToken.json +23 -84
- package/dist/artifacts/core/tokens/RToken.sol/RToken.json +62 -62
- package/dist/artifacts/core/tokens/veRAACToken.sol/veRAACToken.json +2 -2
- package/dist/artifacts/mocks/core/oracles/MockVRFCoordinatorV2.sol/MockVRFCoordinatorV2.json +774 -0
- package/dist/artifacts/zeno/Auction.sol/Auction.json +34 -114
- package/dist/artifacts/zeno/AuctionFactory.sol/AuctionFactory.json +3 -3
- package/dist/artifacts/zeno/Zeno.sol/Zeno.json +3 -3
- package/dist/artifacts/zeno/ZenoFactory.sol/ZenoFactory.json +3 -3
- package/dist/configs/chains/11155111.json +132 -0
- package/dist/configs/chains/17000.json +127 -0
- package/dist/configs/chains/8453.json +26 -14
- package/dist/configs/chains/index.js +4 -0
- package/dist/configs/createConfig.js +6 -0
- package/dist/contracts/feeCollector/claimRewardFromPool.js +24 -0
- package/dist/contracts/housePrices/getLatestPrice.js +1 -1
- package/dist/contracts/indexToken/getNextRandomNFT.js +30 -0
- package/dist/contracts/indexToken/redeemNFT.js +39 -0
- package/dist/methods/commons/estimateGasPrice.js +7 -2
- package/dist/nfts/getAllTokens.js +34 -0
- package/dist/nfts/{addNewBatch.js → getBaseUri.js} +7 -8
- package/dist/nfts/getMintFeePercentage.js +23 -0
- package/dist/nfts/getMintPrice.js +28 -0
- package/dist/nfts/getTokenURI.js +23 -0
- package/dist/nfts/getTokensByOwner.js +35 -0
- package/dist/nfts/getTotalPropertiesCount.js +23 -0
- package/dist/nfts/{getCurrentBatchSize.js → totalNFTSupply.js} +3 -3
- package/dist/pools/lendingPool/borrowFromLendingPool.js +4 -3
- package/dist/pools/lendingPool/borrowFromLendingPoolWithInsurance.js +40 -0
- package/dist/pools/lendingPool/calculateInsuranceFee.js +20 -0
- package/dist/pools/lendingPool/claimReward.js +22 -0
- package/dist/pools/lendingPool/closeLiquidation.js +28 -0
- package/dist/pools/lendingPool/depositNFTToLendingPool.js +0 -1
- package/dist/pools/lendingPool/depositToLendingPool.js +2 -2
- package/dist/pools/lendingPool/getAllUserData.js +28 -0
- package/dist/pools/lendingPool/getEligibleUserDeposits.js +27 -0
- package/dist/pools/lendingPool/getHealthFactor.js +27 -0
- package/dist/pools/lendingPool/getLendingPoolInfo.js +8 -5
- package/dist/pools/lendingPool/getPendingReward.js +20 -0
- package/dist/pools/lendingPool/getPositionDebt.js +27 -0
- package/dist/pools/lendingPool/getPositionScaledDebt.js +27 -0
- package/dist/pools/lendingPool/getPositionView.js +38 -0
- package/dist/pools/lendingPool/getPositionsScaledDebt.js +27 -0
- package/dist/pools/lendingPool/getRawUserDepositsInLendingPool.js +21 -0
- package/dist/pools/lendingPool/getUserCollateralValue.js +27 -0
- package/dist/pools/lendingPool/initializeLiquidation.js +28 -0
- package/dist/pools/lendingPool/repayToLendingPool.js +4 -8
- package/dist/pools/lendingPool/withdrawFromLendingPool.js +2 -2
- package/dist/pools/stabilityPool/depositNFTToStabilityPool.js +40 -0
- package/dist/pools/stabilityPool/getRawUserDepositsInStabilityPool.js +21 -0
- package/dist/pools/stabilityPool/getStabilityPoolInfo.js +2 -12
- package/dist/scripts/index.js +90 -35
- package/dist/types/RPCLibrary.d.ts +61 -8
- package/dist/types/configs/chains/index.d.ts +5 -1
- package/dist/types/configs/createConfig.d.ts +6 -0
- package/dist/types/configs/index.d.ts +2 -0
- package/dist/types/contracts/feeCollector/claimRewardFromPool.d.ts +4 -0
- package/dist/types/contracts/housePrices/getLatestPrice.d.ts +1 -1
- package/dist/types/contracts/indexToken/getNextRandomNFT.d.ts +7 -0
- package/dist/types/contracts/indexToken/redeemNFT.d.ts +4 -0
- package/dist/types/nfts/getAllTokens.d.ts +7 -0
- package/dist/types/nfts/getBaseUri.d.ts +4 -0
- package/dist/types/nfts/getMintFeePercentage.d.ts +4 -0
- package/dist/types/nfts/getMintPrice.d.ts +7 -0
- package/dist/types/nfts/getTokenURI.d.ts +4 -0
- package/dist/types/nfts/getTokensByOwner.d.ts +10 -0
- package/dist/types/nfts/getTotalPropertiesCount.d.ts +4 -0
- package/dist/types/nfts/totalNFTSupply.d.ts +4 -0
- package/dist/types/pools/lendingPool/borrowFromLendingPool.d.ts +1 -1
- package/dist/types/pools/lendingPool/borrowFromLendingPoolWithInsurance.d.ts +4 -0
- package/dist/types/pools/lendingPool/calculateInsuranceFee.d.ts +4 -0
- package/dist/types/pools/lendingPool/claimReward.d.ts +4 -0
- package/dist/types/pools/lendingPool/closeLiquidation.d.ts +11 -0
- package/dist/types/pools/lendingPool/getAllUserData.d.ts +16 -0
- package/dist/types/pools/lendingPool/getEligibleUserDeposits.d.ts +11 -0
- package/dist/types/pools/lendingPool/getHealthFactor.d.ts +11 -0
- package/dist/types/pools/lendingPool/getLendingPoolInfo.d.ts +2 -1
- package/dist/types/pools/lendingPool/getPendingReward.d.ts +4 -0
- package/dist/types/pools/lendingPool/getPositionDebt.d.ts +11 -0
- package/dist/types/pools/lendingPool/getPositionScaledDebt.d.ts +11 -0
- package/dist/types/pools/lendingPool/getPositionView.d.ts +27 -0
- package/dist/types/pools/lendingPool/getPositionsScaledDebt.d.ts +11 -0
- package/dist/types/pools/lendingPool/getRawUserDepositsInLendingPool.d.ts +4 -0
- package/dist/types/pools/lendingPool/getUserCollateralValue.d.ts +11 -0
- package/dist/types/pools/lendingPool/initializeLiquidation.d.ts +11 -0
- package/dist/types/pools/lendingPool/repayToLendingPool.d.ts +2 -2
- package/dist/types/pools/lendingPool/withdrawNFTFromLendingPool.d.ts +1 -1
- package/dist/types/pools/stabilityPool/depositNFTToStabilityPool.d.ts +4 -0
- package/dist/types/pools/stabilityPool/getRawUserDepositsInStabilityPool.d.ts +4 -0
- package/dist/types/pools/stabilityPool/getStabilityPoolInfo.d.ts +1 -3
- package/dist/types/typechain-types/@chainlink/contracts/src/v0.8/index.d.ts +2 -0
- package/dist/types/typechain-types/@chainlink/contracts/src/v0.8/vrf/VRFConsumerBaseV2.d.ts +35 -0
- package/dist/types/typechain-types/@chainlink/contracts/src/v0.8/vrf/index.d.ts +3 -0
- package/dist/types/typechain-types/@chainlink/contracts/src/v0.8/vrf/interfaces/VRFCoordinatorV2Interface.d.ts +156 -0
- package/dist/types/typechain-types/@chainlink/contracts/src/v0.8/vrf/interfaces/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/core/collectors/FeeCollector.d.ts +446 -221
- package/dist/types/typechain-types/contracts/core/minters/RAACMinter/RAACMinter.d.ts +108 -20
- package/dist/types/typechain-types/contracts/core/minters/RAACReleaseOrchestrator/RAACReleaseOrchestrator.d.ts +6 -16
- package/dist/types/typechain-types/contracts/core/oracles/BaseVRFv2Consumer.d.ts +166 -0
- package/dist/types/typechain-types/contracts/core/oracles/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/core/pools/LendingPool/LendingPool.d.ts +811 -99
- package/dist/types/typechain-types/contracts/core/pools/StabilityPool/StabilityPool.d.ts +152 -148
- package/dist/types/typechain-types/contracts/core/pools/StabilityPool/index.d.ts +0 -1
- package/dist/types/typechain-types/contracts/core/primitives/RAACHousePrices.d.ts +29 -2
- package/dist/types/typechain-types/contracts/core/tokens/DebtToken.d.ts +65 -51
- package/dist/types/typechain-types/contracts/core/tokens/IndexToken.d.ts +187 -2
- package/dist/types/typechain-types/contracts/core/tokens/RAACNFT.d.ts +413 -19
- package/dist/types/typechain-types/contracts/core/tokens/RToken.d.ts +40 -40
- package/dist/types/typechain-types/contracts/interfaces/core/collectors/IBaseCollector.d.ts +39 -0
- package/dist/types/typechain-types/contracts/interfaces/core/collectors/IFeeCollector.d.ts +317 -130
- package/dist/types/typechain-types/contracts/interfaces/core/collectors/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/interfaces/core/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/interfaces/core/minters/RAACMinter/IRAACMinter.d.ts +58 -22
- package/dist/types/typechain-types/contracts/interfaces/core/minters/RAACReleaseOrchestrator/IReleaseOrchestrator.d.ts +5 -3
- package/dist/types/typechain-types/contracts/interfaces/core/oracles/IBaseVRFv2Consumer.d.ts +86 -0
- package/dist/types/typechain-types/contracts/interfaces/core/oracles/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/interfaces/core/pools/ILiquidityPool.d.ts +83 -45
- package/dist/types/typechain-types/contracts/interfaces/core/pools/LendingPool/ILendingPool.d.ts +539 -54
- package/dist/types/typechain-types/contracts/interfaces/core/pools/StabilityPool/IStabilityPool.d.ts +92 -71
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IDebtToken.d.ts +123 -27
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IIndexToken.d.ts +187 -0
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IRAACNFT.d.ts +243 -17
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/IRToken.d.ts +37 -37
- package/dist/types/typechain-types/contracts/interfaces/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/interfaces/core/vaults/IBaseVault.d.ts +83 -0
- package/dist/types/typechain-types/contracts/interfaces/core/vaults/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/interfaces/index.d.ts +0 -1
- package/dist/types/typechain-types/contracts/mocks/core/collectors/index.d.ts +0 -1
- package/dist/types/typechain-types/contracts/mocks/core/governance/proposals/TimelockTestTarget.d.ts +5 -1
- package/dist/types/typechain-types/contracts/mocks/core/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/mocks/core/oracles/MockVRFCoordinatorV2.d.ts +530 -0
- package/dist/types/typechain-types/contracts/mocks/core/oracles/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/core/pools/MockLendingPoolCollector.d.ts +156 -0
- package/dist/types/typechain-types/contracts/mocks/core/pools/MockLendingPoolDebtToken.d.ts +557 -102
- package/dist/types/typechain-types/contracts/mocks/core/pools/MockLiquidityPool.d.ts +486 -0
- package/dist/types/typechain-types/contracts/mocks/core/pools/index.d.ts +2 -0
- package/dist/types/typechain-types/contracts/mocks/core/primitives/MockDistributableContract.d.ts +35 -0
- package/dist/types/typechain-types/contracts/mocks/core/primitives/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/core/tokens/MockCollectableUnderlying.d.ts +292 -0
- package/dist/types/typechain-types/contracts/mocks/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/core/vaults/MockVault.d.ts +290 -0
- package/dist/types/typechain-types/contracts/mocks/core/vaults/index.d.ts +1 -0
- package/dist/types/typechain-types/contracts/mocks/libraries/MockStringUtils.d.ts +25 -0
- package/dist/types/typechain-types/contracts/mocks/libraries/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/VRFConsumerBaseV2__factory.d.ts +33 -0
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/interfaces/VRFCoordinatorV2Interface__factory.d.ts +171 -0
- package/dist/types/typechain-types/factories/@chainlink/contracts/src/v0.8/vrf/interfaces/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/core/collectors/FeeCollector__factory.d.ts +571 -194
- package/dist/types/typechain-types/factories/contracts/core/minters/RAACMinter/RAACMinter__factory.d.ts +138 -54
- package/dist/types/typechain-types/factories/contracts/core/minters/RAACReleaseOrchestrator/RAACReleaseOrchestrator__factory.d.ts +5 -31
- package/dist/types/typechain-types/factories/contracts/core/oracles/BaseVRFv2Consumer__factory.d.ts +231 -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/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/core/pools/LendingPool/LendingPool__factory.d.ts +897 -64
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/NFTLiquidator__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/StabilityPool__factory.d.ts +128 -161
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/contracts/core/primitives/RAACHousePrices__factory.d.ts +54 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/DebtToken__factory.d.ts +47 -29
- package/dist/types/typechain-types/factories/contracts/core/tokens/IndexToken__factory.d.ts +317 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/RAACNFT__factory.d.ts +525 -17
- package/dist/types/typechain-types/factories/contracts/core/tokens/RAACToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/core/tokens/RToken__factory.d.ts +52 -52
- package/dist/types/typechain-types/factories/contracts/core/tokens/VeRAACToken__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/interfaces/core/collectors/IBaseCollector__factory.d.ts +33 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/collectors/IFeeCollector__factory.d.ts +409 -90
- package/dist/types/typechain-types/factories/contracts/interfaces/core/collectors/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/minters/RAACMinter/IRAACMinter__factory.d.ts +59 -15
- package/dist/types/typechain-types/factories/contracts/interfaces/core/minters/RAACReleaseOrchestrator/IReleaseOrchestrator__factory.d.ts +4 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/oracles/IBaseVRFv2Consumer__factory.d.ts +78 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/oracles/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/core/pools/ILiquidityPool__factory.d.ts +119 -39
- package/dist/types/typechain-types/factories/contracts/interfaces/core/pools/LendingPool/ILendingPool__factory.d.ts +547 -19
- package/dist/types/typechain-types/factories/contracts/interfaces/core/pools/StabilityPool/IStabilityPool__factory.d.ts +68 -67
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IDebtToken__factory.d.ts +119 -6
- package/dist/types/typechain-types/factories/{erc721a/contracts/IERC721A__factory.d.ts → contracts/interfaces/core/tokens/IIndexToken__factory.d.ts} +74 -215
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IRAACNFT__factory.d.ts +274 -10
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/IRToken__factory.d.ts +26 -26
- package/dist/types/typechain-types/factories/contracts/interfaces/core/tokens/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/{IMarketCreator__factory.d.ts → core/vaults/IBaseVault__factory.d.ts} +78 -42
- package/dist/types/typechain-types/factories/contracts/interfaces/core/vaults/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/interfaces/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/contracts/libraries/pools/ReserveLibrary__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/collectors/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/gauges/MockBaseGauge__factory.d.ts +16 -4
- package/dist/types/typechain-types/factories/contracts/mocks/core/governance/proposals/TimelockTestTarget__factory.d.ts +10 -1
- package/dist/types/typechain-types/factories/contracts/mocks/core/index.d.ts +1 -0
- 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/MockVRFCoordinatorV2__factory.d.ts +620 -0
- 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/oracles/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLendingPoolCollector__factory.d.ts +234 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/pools/MockLendingPoolDebtToken__factory.d.ts +539 -77
- 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 +795 -0
- 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/pools/index.d.ts +2 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/MockDistributableContract__factory.d.ts +68 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/primitives/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/tokens/MockCollectableUnderlying__factory.d.ts +451 -0
- 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 +525 -0
- package/dist/types/typechain-types/factories/contracts/mocks/core/vaults/index.d.ts +1 -0
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/MockStringUtils__factory.d.ts +40 -0
- package/dist/types/typechain-types/factories/contracts/mocks/libraries/index.d.ts +1 -0
- 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/VeRAACFuzzHelper__factory.d.ts +1 -1
- package/dist/types/typechain-types/factories/index.d.ts +0 -1
- package/dist/types/typechain-types/index.d.ts +28 -10
- package/dist/types/utils/artifacts.d.ts +677 -39
- package/dist/types/utils/contracts.d.ts +4 -0
- package/dist/utils/artifacts.js +9 -0
- package/package.json +1 -1
- package/dist/nfts/getDepositedNFTs.js +0 -19
- package/dist/nfts/getOwnedNFTs.js +0 -34
- package/dist/types/nfts/addNewBatch.d.ts +0 -4
- package/dist/types/nfts/getCurrentBatchSize.d.ts +0 -4
- package/dist/types/nfts/getDepositedNFTs.d.ts +0 -7
- package/dist/types/nfts/getOwnedNFTs.d.ts +0 -7
- package/dist/types/typechain-types/contracts/core/pools/StabilityPool/MarketCreator.d.ts +0 -274
- package/dist/types/typechain-types/contracts/interfaces/IMarketCreator.d.ts +0 -85
- package/dist/types/typechain-types/contracts/mocks/core/collectors/MockFeeCollector.d.ts +0 -708
- package/dist/types/typechain-types/erc721a/contracts/IERC721A.d.ts +0 -242
- package/dist/types/typechain-types/erc721a/contracts/index.d.ts +0 -1
- package/dist/types/typechain-types/erc721a/index.d.ts +0 -2
- package/dist/types/typechain-types/factories/contracts/core/pools/StabilityPool/MarketCreator__factory.d.ts +0 -405
- package/dist/types/typechain-types/factories/contracts/mocks/core/collectors/MockFeeCollector__factory.d.ts +0 -985
- package/dist/types/typechain-types/factories/erc721a/contracts/index.d.ts +0 -1
- package/dist/types/typechain-types/factories/erc721a/index.d.ts +0 -1
|
@@ -3,6 +3,8 @@ import { ContractType } from "./artifacts";
|
|
|
3
3
|
import { ethers, Provider } from "ethers";
|
|
4
4
|
export declare const getConfigs: () => {
|
|
5
5
|
8453: import("../configs/chains/chain").Chain8453;
|
|
6
|
+
17000: import("../configs/chains/chain").Chain8453;
|
|
7
|
+
11155111: import("../configs/chains/chain").Chain11155111;
|
|
6
8
|
};
|
|
7
9
|
export declare const setOverrideConfig: (chainId: ChainId, newConfig: any) => void;
|
|
8
10
|
export declare const getConfig: (chainId: ChainId) => any;
|
|
@@ -15,6 +17,8 @@ declare const _default: {
|
|
|
15
17
|
getConfig: (chainId: ChainId) => any;
|
|
16
18
|
getConfigs: () => {
|
|
17
19
|
8453: import("../configs/chains/chain").Chain8453;
|
|
20
|
+
17000: import("../configs/chains/chain").Chain8453;
|
|
21
|
+
11155111: import("../configs/chains/chain").Chain11155111;
|
|
18
22
|
};
|
|
19
23
|
};
|
|
20
24
|
export default _default;
|
package/dist/utils/artifacts.js
CHANGED
|
@@ -19,6 +19,10 @@ const AuctionFactory_json_1 = __importDefault(require("../artifacts/zeno/Auction
|
|
|
19
19
|
const Auction_json_1 = __importDefault(require("../artifacts/zeno/Auction.sol/Auction.json")); // assert { type: "json" };
|
|
20
20
|
const ZenoFactory_json_1 = __importDefault(require("../artifacts/zeno/ZenoFactory.sol/ZenoFactory.json")); // assert { type: "json" };
|
|
21
21
|
const Zeno_json_1 = __importDefault(require("../artifacts/zeno/Zeno.sol/Zeno.json")); // assert { type: "json" };
|
|
22
|
+
const FeeCollector_json_1 = __importDefault(require("../artifacts/core/collectors/FeeCollector.sol/FeeCollector.json")); // assert { type: "json" };
|
|
23
|
+
const IndexToken_json_1 = __importDefault(require("../artifacts/core/tokens/IndexToken.sol/IndexToken.json")); // assert { type: "json" };
|
|
24
|
+
const MockVRFCoordinatorV2_json_1 = __importDefault(require("../artifacts/mocks/core/oracles/MockVRFCoordinatorV2.sol/MockVRFCoordinatorV2.json")); // assert { type: "json" };
|
|
25
|
+
const BaseVRFv2Consumer_json_1 = __importDefault(require("../artifacts/core/oracles/BaseVRFv2Consumer.sol/BaseVRFv2Consumer.json")); // assert { type: "json" };
|
|
22
26
|
const CRVUSD_ABI = crvUSDToken_json_1.default.abi;
|
|
23
27
|
const RToken_json_2 = __importDefault(require("../artifacts/core/tokens/RToken.sol/RToken.json")); // assert { type: "json" }; // TODO: Isnt this same as rcrvusd?
|
|
24
28
|
const RTOKEN_ABI = RToken_json_2.default.abi;
|
|
@@ -32,6 +36,7 @@ const RAACMINTER_ABI = RAACMinter_json_1.default.abi;
|
|
|
32
36
|
const RAACNFT_ABI = RAACNFT_json_1.default.abi;
|
|
33
37
|
const RAACToken_ABI = RAACToken_json_1.default.abi;
|
|
34
38
|
const RAACHOUSEPRICES_ABI = RAACHousePrices_json_1.default.abi;
|
|
39
|
+
const FEECOLLECTOR_ABI = FeeCollector_json_1.default.abi;
|
|
35
40
|
const ABIS = {
|
|
36
41
|
// Tokens
|
|
37
42
|
crvusd: CRVUSD_ABI,
|
|
@@ -51,11 +56,15 @@ const ABIS = {
|
|
|
51
56
|
// contracts
|
|
52
57
|
// contracts#raacHousePrices
|
|
53
58
|
raachouseprices: RAACHOUSEPRICES_ABI,
|
|
59
|
+
feecollector: FEECOLLECTOR_ABI,
|
|
54
60
|
// contracts#auction
|
|
55
61
|
auction: Auction_json_1.default.abi,
|
|
56
62
|
auctionfactory: AuctionFactory_json_1.default.abi,
|
|
57
63
|
zeno: Zeno_json_1.default.abi,
|
|
58
64
|
zenofactory: ZenoFactory_json_1.default.abi,
|
|
65
|
+
indextoken: IndexToken_json_1.default.abi,
|
|
66
|
+
mockvrfcoordinator: MockVRFCoordinatorV2_json_1.default.abi,
|
|
67
|
+
vrfconsumer: BaseVRFv2Consumer_json_1.default.abi,
|
|
59
68
|
eth: [],
|
|
60
69
|
};
|
|
61
70
|
exports.ABIS = ABIS;
|
package/package.json
CHANGED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const ethers_1 = require("ethers");
|
|
4
|
-
const contracts_1 = require("../utils/contracts");
|
|
5
|
-
const artifacts_1 = require("../utils/artifacts");
|
|
6
|
-
async function getDepositedNFTs(chainId, address, provider) {
|
|
7
|
-
try {
|
|
8
|
-
const lendingPoolAddress = (0, contracts_1.getContractAddress)(chainId, "lendingpool");
|
|
9
|
-
const lendingPoolABI = (0, artifacts_1.getABI)("lendingpool");
|
|
10
|
-
const lendingPoolContract = new ethers_1.ethers.Contract(lendingPoolAddress, lendingPoolABI, provider);
|
|
11
|
-
const nftTokenIds = await lendingPoolContract.getUserDepositedNFTs(address);
|
|
12
|
-
return { address, nftTokenIds };
|
|
13
|
-
}
|
|
14
|
-
catch (error) {
|
|
15
|
-
console.error("Error getting deposited NFTs:", error);
|
|
16
|
-
throw new Error(`Failed to get deposited NFTs: ${error.message}`);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
exports.default = getDepositedNFTs;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const ethers_1 = require("ethers");
|
|
4
|
-
const contracts_1 = require("../utils/contracts");
|
|
5
|
-
const artifacts_1 = require("../utils/artifacts");
|
|
6
|
-
async function getOwnedNFTs(chainId, address, provider) {
|
|
7
|
-
try {
|
|
8
|
-
const raacNFTAddress = (0, contracts_1.getContractAddress)(chainId, "raacnft");
|
|
9
|
-
const raacNFTABI = (0, artifacts_1.getABI)("raacnft");
|
|
10
|
-
const raacNFTContract = new ethers_1.ethers.Contract(raacNFTAddress, raacNFTABI, provider);
|
|
11
|
-
const ownedTokens = [];
|
|
12
|
-
try {
|
|
13
|
-
const balance = await raacNFTContract.balanceOf(address);
|
|
14
|
-
for (let i = 0; i < balance; i++) {
|
|
15
|
-
try {
|
|
16
|
-
const tokenId = await raacNFTContract.tokenOfOwnerByIndex(address, i);
|
|
17
|
-
ownedTokens.push(tokenId.toString());
|
|
18
|
-
}
|
|
19
|
-
catch (error) {
|
|
20
|
-
console.error("Error getting owned NFTs:", error);
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
catch (error) {
|
|
25
|
-
console.error("Error getting owned NFTs:", error);
|
|
26
|
-
}
|
|
27
|
-
return { address, ownedTokens };
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error("Error getting owned NFTs:", error);
|
|
31
|
-
throw new Error(`Failed to get owned NFTs: ${error.message}`);
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
exports.default = getOwnedNFTs;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { Provider } from "ethers";
|
|
2
|
-
import { ChainId } from "../configs/chains/index";
|
|
3
|
-
declare function getDepositedNFTs(chainId: ChainId, address: string, provider: Provider): Promise<{
|
|
4
|
-
address: string;
|
|
5
|
-
nftTokenIds: bigint[];
|
|
6
|
-
}>;
|
|
7
|
-
export default getDepositedNFTs;
|
|
@@ -1,274 +0,0 @@
|
|
|
1
|
-
import type { BaseContract, BigNumberish, BytesLike, FunctionFragment, Result, Interface, EventFragment, AddressLike, ContractRunner, ContractMethod, Listener } from "ethers";
|
|
2
|
-
import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener, TypedContractMethod } from "../../../../common";
|
|
3
|
-
export interface MarketCreatorInterface extends Interface {
|
|
4
|
-
getFunction(nameOrSignature: "MAX_LOCK_DURATION" | "MAX_REWARD" | "createMarket" | "decrvUSDToken" | "getMarketInfo" | "getUserPosition" | "marketCount" | "markets" | "owner" | "participateInMarket" | "raacToken" | "redeemFromMarket" | "renounceOwnership" | "transferOwnership" | "userPositions"): FunctionFragment;
|
|
5
|
-
getEvent(nameOrSignatureOrTopic: "MarketCreated" | "OwnershipTransferred" | "Participated" | "Redeemed"): EventFragment;
|
|
6
|
-
encodeFunctionData(functionFragment: "MAX_LOCK_DURATION", values?: undefined): string;
|
|
7
|
-
encodeFunctionData(functionFragment: "MAX_REWARD", values?: undefined): string;
|
|
8
|
-
encodeFunctionData(functionFragment: "createMarket", values: [AddressLike, BigNumberish, BigNumberish]): string;
|
|
9
|
-
encodeFunctionData(functionFragment: "decrvUSDToken", values?: undefined): string;
|
|
10
|
-
encodeFunctionData(functionFragment: "getMarketInfo", values: [BigNumberish]): string;
|
|
11
|
-
encodeFunctionData(functionFragment: "getUserPosition", values: [BigNumberish, AddressLike]): string;
|
|
12
|
-
encodeFunctionData(functionFragment: "marketCount", values?: undefined): string;
|
|
13
|
-
encodeFunctionData(functionFragment: "markets", values: [BigNumberish]): string;
|
|
14
|
-
encodeFunctionData(functionFragment: "owner", values?: undefined): string;
|
|
15
|
-
encodeFunctionData(functionFragment: "participateInMarket", values: [BigNumberish, BigNumberish]): string;
|
|
16
|
-
encodeFunctionData(functionFragment: "raacToken", values?: undefined): string;
|
|
17
|
-
encodeFunctionData(functionFragment: "redeemFromMarket", values: [BigNumberish]): string;
|
|
18
|
-
encodeFunctionData(functionFragment: "renounceOwnership", values?: undefined): string;
|
|
19
|
-
encodeFunctionData(functionFragment: "transferOwnership", values: [AddressLike]): string;
|
|
20
|
-
encodeFunctionData(functionFragment: "userPositions", values: [BigNumberish, AddressLike]): string;
|
|
21
|
-
decodeFunctionResult(functionFragment: "MAX_LOCK_DURATION", data: BytesLike): Result;
|
|
22
|
-
decodeFunctionResult(functionFragment: "MAX_REWARD", data: BytesLike): Result;
|
|
23
|
-
decodeFunctionResult(functionFragment: "createMarket", data: BytesLike): Result;
|
|
24
|
-
decodeFunctionResult(functionFragment: "decrvUSDToken", data: BytesLike): Result;
|
|
25
|
-
decodeFunctionResult(functionFragment: "getMarketInfo", data: BytesLike): Result;
|
|
26
|
-
decodeFunctionResult(functionFragment: "getUserPosition", data: BytesLike): Result;
|
|
27
|
-
decodeFunctionResult(functionFragment: "marketCount", data: BytesLike): Result;
|
|
28
|
-
decodeFunctionResult(functionFragment: "markets", data: BytesLike): Result;
|
|
29
|
-
decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result;
|
|
30
|
-
decodeFunctionResult(functionFragment: "participateInMarket", data: BytesLike): Result;
|
|
31
|
-
decodeFunctionResult(functionFragment: "raacToken", data: BytesLike): Result;
|
|
32
|
-
decodeFunctionResult(functionFragment: "redeemFromMarket", data: BytesLike): Result;
|
|
33
|
-
decodeFunctionResult(functionFragment: "renounceOwnership", data: BytesLike): Result;
|
|
34
|
-
decodeFunctionResult(functionFragment: "transferOwnership", data: BytesLike): Result;
|
|
35
|
-
decodeFunctionResult(functionFragment: "userPositions", data: BytesLike): Result;
|
|
36
|
-
}
|
|
37
|
-
export declare namespace MarketCreatedEvent {
|
|
38
|
-
type InputTuple = [
|
|
39
|
-
marketId: BigNumberish,
|
|
40
|
-
quoteAsset: AddressLike,
|
|
41
|
-
lockDuration: BigNumberish,
|
|
42
|
-
reward: BigNumberish
|
|
43
|
-
];
|
|
44
|
-
type OutputTuple = [
|
|
45
|
-
marketId: bigint,
|
|
46
|
-
quoteAsset: string,
|
|
47
|
-
lockDuration: bigint,
|
|
48
|
-
reward: bigint
|
|
49
|
-
];
|
|
50
|
-
interface OutputObject {
|
|
51
|
-
marketId: bigint;
|
|
52
|
-
quoteAsset: string;
|
|
53
|
-
lockDuration: bigint;
|
|
54
|
-
reward: bigint;
|
|
55
|
-
}
|
|
56
|
-
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
57
|
-
type Filter = TypedDeferredTopicFilter<Event>;
|
|
58
|
-
type Log = TypedEventLog<Event>;
|
|
59
|
-
type LogDescription = TypedLogDescription<Event>;
|
|
60
|
-
}
|
|
61
|
-
export declare namespace OwnershipTransferredEvent {
|
|
62
|
-
type InputTuple = [previousOwner: AddressLike, newOwner: AddressLike];
|
|
63
|
-
type OutputTuple = [previousOwner: string, newOwner: string];
|
|
64
|
-
interface OutputObject {
|
|
65
|
-
previousOwner: string;
|
|
66
|
-
newOwner: string;
|
|
67
|
-
}
|
|
68
|
-
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
69
|
-
type Filter = TypedDeferredTopicFilter<Event>;
|
|
70
|
-
type Log = TypedEventLog<Event>;
|
|
71
|
-
type LogDescription = TypedLogDescription<Event>;
|
|
72
|
-
}
|
|
73
|
-
export declare namespace ParticipatedEvent {
|
|
74
|
-
type InputTuple = [
|
|
75
|
-
marketId: BigNumberish,
|
|
76
|
-
user: AddressLike,
|
|
77
|
-
amount: BigNumberish
|
|
78
|
-
];
|
|
79
|
-
type OutputTuple = [marketId: bigint, user: string, amount: bigint];
|
|
80
|
-
interface OutputObject {
|
|
81
|
-
marketId: bigint;
|
|
82
|
-
user: string;
|
|
83
|
-
amount: bigint;
|
|
84
|
-
}
|
|
85
|
-
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
86
|
-
type Filter = TypedDeferredTopicFilter<Event>;
|
|
87
|
-
type Log = TypedEventLog<Event>;
|
|
88
|
-
type LogDescription = TypedLogDescription<Event>;
|
|
89
|
-
}
|
|
90
|
-
export declare namespace RedeemedEvent {
|
|
91
|
-
type InputTuple = [
|
|
92
|
-
marketId: BigNumberish,
|
|
93
|
-
user: AddressLike,
|
|
94
|
-
amount: BigNumberish,
|
|
95
|
-
reward: BigNumberish
|
|
96
|
-
];
|
|
97
|
-
type OutputTuple = [
|
|
98
|
-
marketId: bigint,
|
|
99
|
-
user: string,
|
|
100
|
-
amount: bigint,
|
|
101
|
-
reward: bigint
|
|
102
|
-
];
|
|
103
|
-
interface OutputObject {
|
|
104
|
-
marketId: bigint;
|
|
105
|
-
user: string;
|
|
106
|
-
amount: bigint;
|
|
107
|
-
reward: bigint;
|
|
108
|
-
}
|
|
109
|
-
type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>;
|
|
110
|
-
type Filter = TypedDeferredTopicFilter<Event>;
|
|
111
|
-
type Log = TypedEventLog<Event>;
|
|
112
|
-
type LogDescription = TypedLogDescription<Event>;
|
|
113
|
-
}
|
|
114
|
-
export interface MarketCreator extends BaseContract {
|
|
115
|
-
connect(runner?: ContractRunner | null): MarketCreator;
|
|
116
|
-
waitForDeployment(): Promise<this>;
|
|
117
|
-
interface: MarketCreatorInterface;
|
|
118
|
-
queryFilter<TCEvent extends TypedContractEvent>(event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
119
|
-
queryFilter<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
120
|
-
on<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
121
|
-
on<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
122
|
-
once<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
123
|
-
once<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
124
|
-
listeners<TCEvent extends TypedContractEvent>(event: TCEvent): Promise<Array<TypedListener<TCEvent>>>;
|
|
125
|
-
listeners(eventName?: string): Promise<Array<Listener>>;
|
|
126
|
-
removeAllListeners<TCEvent extends TypedContractEvent>(event?: TCEvent): Promise<this>;
|
|
127
|
-
MAX_LOCK_DURATION: TypedContractMethod<[], [bigint], "view">;
|
|
128
|
-
MAX_REWARD: TypedContractMethod<[], [bigint], "view">;
|
|
129
|
-
createMarket: TypedContractMethod<[
|
|
130
|
-
_quoteAsset: AddressLike,
|
|
131
|
-
_lockDuration: BigNumberish,
|
|
132
|
-
_reward: BigNumberish
|
|
133
|
-
], [
|
|
134
|
-
void
|
|
135
|
-
], "nonpayable">;
|
|
136
|
-
decrvUSDToken: TypedContractMethod<[], [string], "view">;
|
|
137
|
-
getMarketInfo: TypedContractMethod<[
|
|
138
|
-
marketId: BigNumberish
|
|
139
|
-
], [
|
|
140
|
-
[string, bigint, bigint, bigint]
|
|
141
|
-
], "view">;
|
|
142
|
-
getUserPosition: TypedContractMethod<[
|
|
143
|
-
marketId: BigNumberish,
|
|
144
|
-
user: AddressLike
|
|
145
|
-
], [
|
|
146
|
-
[bigint, bigint, boolean]
|
|
147
|
-
], "view">;
|
|
148
|
-
marketCount: TypedContractMethod<[], [bigint], "view">;
|
|
149
|
-
markets: TypedContractMethod<[
|
|
150
|
-
arg0: BigNumberish
|
|
151
|
-
], [
|
|
152
|
-
[
|
|
153
|
-
string,
|
|
154
|
-
bigint,
|
|
155
|
-
bigint,
|
|
156
|
-
bigint
|
|
157
|
-
] & {
|
|
158
|
-
quoteAsset: string;
|
|
159
|
-
lockDuration: bigint;
|
|
160
|
-
reward: bigint;
|
|
161
|
-
totalDeposits: bigint;
|
|
162
|
-
}
|
|
163
|
-
], "view">;
|
|
164
|
-
owner: TypedContractMethod<[], [string], "view">;
|
|
165
|
-
participateInMarket: TypedContractMethod<[
|
|
166
|
-
marketId: BigNumberish,
|
|
167
|
-
amount: BigNumberish
|
|
168
|
-
], [
|
|
169
|
-
void
|
|
170
|
-
], "nonpayable">;
|
|
171
|
-
raacToken: TypedContractMethod<[], [string], "view">;
|
|
172
|
-
redeemFromMarket: TypedContractMethod<[
|
|
173
|
-
marketId: BigNumberish
|
|
174
|
-
], [
|
|
175
|
-
void
|
|
176
|
-
], "nonpayable">;
|
|
177
|
-
renounceOwnership: TypedContractMethod<[], [void], "nonpayable">;
|
|
178
|
-
transferOwnership: TypedContractMethod<[
|
|
179
|
-
newOwner: AddressLike
|
|
180
|
-
], [
|
|
181
|
-
void
|
|
182
|
-
], "nonpayable">;
|
|
183
|
-
userPositions: TypedContractMethod<[
|
|
184
|
-
arg0: BigNumberish,
|
|
185
|
-
arg1: AddressLike
|
|
186
|
-
], [
|
|
187
|
-
[
|
|
188
|
-
bigint,
|
|
189
|
-
bigint,
|
|
190
|
-
boolean
|
|
191
|
-
] & {
|
|
192
|
-
amount: bigint;
|
|
193
|
-
lockEndTime: bigint;
|
|
194
|
-
exists: boolean;
|
|
195
|
-
}
|
|
196
|
-
], "view">;
|
|
197
|
-
getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T;
|
|
198
|
-
getFunction(nameOrSignature: "MAX_LOCK_DURATION"): TypedContractMethod<[], [bigint], "view">;
|
|
199
|
-
getFunction(nameOrSignature: "MAX_REWARD"): TypedContractMethod<[], [bigint], "view">;
|
|
200
|
-
getFunction(nameOrSignature: "createMarket"): TypedContractMethod<[
|
|
201
|
-
_quoteAsset: AddressLike,
|
|
202
|
-
_lockDuration: BigNumberish,
|
|
203
|
-
_reward: BigNumberish
|
|
204
|
-
], [
|
|
205
|
-
void
|
|
206
|
-
], "nonpayable">;
|
|
207
|
-
getFunction(nameOrSignature: "decrvUSDToken"): TypedContractMethod<[], [string], "view">;
|
|
208
|
-
getFunction(nameOrSignature: "getMarketInfo"): TypedContractMethod<[
|
|
209
|
-
marketId: BigNumberish
|
|
210
|
-
], [
|
|
211
|
-
[string, bigint, bigint, bigint]
|
|
212
|
-
], "view">;
|
|
213
|
-
getFunction(nameOrSignature: "getUserPosition"): TypedContractMethod<[
|
|
214
|
-
marketId: BigNumberish,
|
|
215
|
-
user: AddressLike
|
|
216
|
-
], [
|
|
217
|
-
[bigint, bigint, boolean]
|
|
218
|
-
], "view">;
|
|
219
|
-
getFunction(nameOrSignature: "marketCount"): TypedContractMethod<[], [bigint], "view">;
|
|
220
|
-
getFunction(nameOrSignature: "markets"): TypedContractMethod<[
|
|
221
|
-
arg0: BigNumberish
|
|
222
|
-
], [
|
|
223
|
-
[
|
|
224
|
-
string,
|
|
225
|
-
bigint,
|
|
226
|
-
bigint,
|
|
227
|
-
bigint
|
|
228
|
-
] & {
|
|
229
|
-
quoteAsset: string;
|
|
230
|
-
lockDuration: bigint;
|
|
231
|
-
reward: bigint;
|
|
232
|
-
totalDeposits: bigint;
|
|
233
|
-
}
|
|
234
|
-
], "view">;
|
|
235
|
-
getFunction(nameOrSignature: "owner"): TypedContractMethod<[], [string], "view">;
|
|
236
|
-
getFunction(nameOrSignature: "participateInMarket"): TypedContractMethod<[
|
|
237
|
-
marketId: BigNumberish,
|
|
238
|
-
amount: BigNumberish
|
|
239
|
-
], [
|
|
240
|
-
void
|
|
241
|
-
], "nonpayable">;
|
|
242
|
-
getFunction(nameOrSignature: "raacToken"): TypedContractMethod<[], [string], "view">;
|
|
243
|
-
getFunction(nameOrSignature: "redeemFromMarket"): TypedContractMethod<[marketId: BigNumberish], [void], "nonpayable">;
|
|
244
|
-
getFunction(nameOrSignature: "renounceOwnership"): TypedContractMethod<[], [void], "nonpayable">;
|
|
245
|
-
getFunction(nameOrSignature: "transferOwnership"): TypedContractMethod<[newOwner: AddressLike], [void], "nonpayable">;
|
|
246
|
-
getFunction(nameOrSignature: "userPositions"): TypedContractMethod<[
|
|
247
|
-
arg0: BigNumberish,
|
|
248
|
-
arg1: AddressLike
|
|
249
|
-
], [
|
|
250
|
-
[
|
|
251
|
-
bigint,
|
|
252
|
-
bigint,
|
|
253
|
-
boolean
|
|
254
|
-
] & {
|
|
255
|
-
amount: bigint;
|
|
256
|
-
lockEndTime: bigint;
|
|
257
|
-
exists: boolean;
|
|
258
|
-
}
|
|
259
|
-
], "view">;
|
|
260
|
-
getEvent(key: "MarketCreated"): TypedContractEvent<MarketCreatedEvent.InputTuple, MarketCreatedEvent.OutputTuple, MarketCreatedEvent.OutputObject>;
|
|
261
|
-
getEvent(key: "OwnershipTransferred"): TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
262
|
-
getEvent(key: "Participated"): TypedContractEvent<ParticipatedEvent.InputTuple, ParticipatedEvent.OutputTuple, ParticipatedEvent.OutputObject>;
|
|
263
|
-
getEvent(key: "Redeemed"): TypedContractEvent<RedeemedEvent.InputTuple, RedeemedEvent.OutputTuple, RedeemedEvent.OutputObject>;
|
|
264
|
-
filters: {
|
|
265
|
-
"MarketCreated(uint256,address,uint256,uint256)": TypedContractEvent<MarketCreatedEvent.InputTuple, MarketCreatedEvent.OutputTuple, MarketCreatedEvent.OutputObject>;
|
|
266
|
-
MarketCreated: TypedContractEvent<MarketCreatedEvent.InputTuple, MarketCreatedEvent.OutputTuple, MarketCreatedEvent.OutputObject>;
|
|
267
|
-
"OwnershipTransferred(address,address)": TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
268
|
-
OwnershipTransferred: TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>;
|
|
269
|
-
"Participated(uint256,address,uint256)": TypedContractEvent<ParticipatedEvent.InputTuple, ParticipatedEvent.OutputTuple, ParticipatedEvent.OutputObject>;
|
|
270
|
-
Participated: TypedContractEvent<ParticipatedEvent.InputTuple, ParticipatedEvent.OutputTuple, ParticipatedEvent.OutputObject>;
|
|
271
|
-
"Redeemed(uint256,address,uint256,uint256)": TypedContractEvent<RedeemedEvent.InputTuple, RedeemedEvent.OutputTuple, RedeemedEvent.OutputObject>;
|
|
272
|
-
Redeemed: TypedContractEvent<RedeemedEvent.InputTuple, RedeemedEvent.OutputTuple, RedeemedEvent.OutputObject>;
|
|
273
|
-
};
|
|
274
|
-
}
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import type { BaseContract, BigNumberish, BytesLike, FunctionFragment, Result, Interface, AddressLike, ContractRunner, ContractMethod, Listener } from "ethers";
|
|
2
|
-
import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedListener, TypedContractMethod } from "../../common";
|
|
3
|
-
export interface IMarketCreatorInterface extends Interface {
|
|
4
|
-
getFunction(nameOrSignature: "createMarket" | "getMarketInfo" | "getUserPosition" | "participateInMarket" | "redeemFromMarket"): FunctionFragment;
|
|
5
|
-
encodeFunctionData(functionFragment: "createMarket", values: [AddressLike, BigNumberish, BigNumberish]): string;
|
|
6
|
-
encodeFunctionData(functionFragment: "getMarketInfo", values: [BigNumberish]): string;
|
|
7
|
-
encodeFunctionData(functionFragment: "getUserPosition", values: [BigNumberish, AddressLike]): string;
|
|
8
|
-
encodeFunctionData(functionFragment: "participateInMarket", values: [BigNumberish, BigNumberish]): string;
|
|
9
|
-
encodeFunctionData(functionFragment: "redeemFromMarket", values: [BigNumberish]): string;
|
|
10
|
-
decodeFunctionResult(functionFragment: "createMarket", data: BytesLike): Result;
|
|
11
|
-
decodeFunctionResult(functionFragment: "getMarketInfo", data: BytesLike): Result;
|
|
12
|
-
decodeFunctionResult(functionFragment: "getUserPosition", data: BytesLike): Result;
|
|
13
|
-
decodeFunctionResult(functionFragment: "participateInMarket", data: BytesLike): Result;
|
|
14
|
-
decodeFunctionResult(functionFragment: "redeemFromMarket", data: BytesLike): Result;
|
|
15
|
-
}
|
|
16
|
-
export interface IMarketCreator extends BaseContract {
|
|
17
|
-
connect(runner?: ContractRunner | null): IMarketCreator;
|
|
18
|
-
waitForDeployment(): Promise<this>;
|
|
19
|
-
interface: IMarketCreatorInterface;
|
|
20
|
-
queryFilter<TCEvent extends TypedContractEvent>(event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
21
|
-
queryFilter<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>;
|
|
22
|
-
on<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
23
|
-
on<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
24
|
-
once<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>;
|
|
25
|
-
once<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>;
|
|
26
|
-
listeners<TCEvent extends TypedContractEvent>(event: TCEvent): Promise<Array<TypedListener<TCEvent>>>;
|
|
27
|
-
listeners(eventName?: string): Promise<Array<Listener>>;
|
|
28
|
-
removeAllListeners<TCEvent extends TypedContractEvent>(event?: TCEvent): Promise<this>;
|
|
29
|
-
createMarket: TypedContractMethod<[
|
|
30
|
-
_quoteAsset: AddressLike,
|
|
31
|
-
_lockDuration: BigNumberish,
|
|
32
|
-
_reward: BigNumberish
|
|
33
|
-
], [
|
|
34
|
-
void
|
|
35
|
-
], "nonpayable">;
|
|
36
|
-
getMarketInfo: TypedContractMethod<[
|
|
37
|
-
marketId: BigNumberish
|
|
38
|
-
], [
|
|
39
|
-
[string, bigint, bigint, bigint]
|
|
40
|
-
], "view">;
|
|
41
|
-
getUserPosition: TypedContractMethod<[
|
|
42
|
-
marketId: BigNumberish,
|
|
43
|
-
user: AddressLike
|
|
44
|
-
], [
|
|
45
|
-
[bigint, bigint, boolean]
|
|
46
|
-
], "view">;
|
|
47
|
-
participateInMarket: TypedContractMethod<[
|
|
48
|
-
marketId: BigNumberish,
|
|
49
|
-
amount: BigNumberish
|
|
50
|
-
], [
|
|
51
|
-
void
|
|
52
|
-
], "nonpayable">;
|
|
53
|
-
redeemFromMarket: TypedContractMethod<[
|
|
54
|
-
marketId: BigNumberish
|
|
55
|
-
], [
|
|
56
|
-
void
|
|
57
|
-
], "nonpayable">;
|
|
58
|
-
getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T;
|
|
59
|
-
getFunction(nameOrSignature: "createMarket"): TypedContractMethod<[
|
|
60
|
-
_quoteAsset: AddressLike,
|
|
61
|
-
_lockDuration: BigNumberish,
|
|
62
|
-
_reward: BigNumberish
|
|
63
|
-
], [
|
|
64
|
-
void
|
|
65
|
-
], "nonpayable">;
|
|
66
|
-
getFunction(nameOrSignature: "getMarketInfo"): TypedContractMethod<[
|
|
67
|
-
marketId: BigNumberish
|
|
68
|
-
], [
|
|
69
|
-
[string, bigint, bigint, bigint]
|
|
70
|
-
], "view">;
|
|
71
|
-
getFunction(nameOrSignature: "getUserPosition"): TypedContractMethod<[
|
|
72
|
-
marketId: BigNumberish,
|
|
73
|
-
user: AddressLike
|
|
74
|
-
], [
|
|
75
|
-
[bigint, bigint, boolean]
|
|
76
|
-
], "view">;
|
|
77
|
-
getFunction(nameOrSignature: "participateInMarket"): TypedContractMethod<[
|
|
78
|
-
marketId: BigNumberish,
|
|
79
|
-
amount: BigNumberish
|
|
80
|
-
], [
|
|
81
|
-
void
|
|
82
|
-
], "nonpayable">;
|
|
83
|
-
getFunction(nameOrSignature: "redeemFromMarket"): TypedContractMethod<[marketId: BigNumberish], [void], "nonpayable">;
|
|
84
|
-
filters: {};
|
|
85
|
-
}
|