@towns-labs/web3 2.0.1
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/README.md +3 -0
- package/dist/BaseContractShim.d.ts +57 -0
- package/dist/BaseContractShim.d.ts.map +1 -0
- package/dist/BaseContractShim.js +224 -0
- package/dist/BaseContractShim.js.map +1 -0
- package/dist/airdrop/IDropFacetShim.d.ts +9 -0
- package/dist/airdrop/IDropFacetShim.d.ts.map +1 -0
- package/dist/airdrop/IDropFacetShim.js +9 -0
- package/dist/airdrop/IDropFacetShim.js.map +1 -0
- package/dist/airdrop/IRiverPointsShim.d.ts +9 -0
- package/dist/airdrop/IRiverPointsShim.d.ts.map +1 -0
- package/dist/airdrop/IRiverPointsShim.js +9 -0
- package/dist/airdrop/IRiverPointsShim.js.map +1 -0
- package/dist/airdrop/RiverAirdropDapp.d.ts +16 -0
- package/dist/airdrop/RiverAirdropDapp.d.ts.map +1 -0
- package/dist/airdrop/RiverAirdropDapp.js +30 -0
- package/dist/airdrop/RiverAirdropDapp.js.map +1 -0
- package/dist/app-registry/AppRegistryDapp.d.ts +68 -0
- package/dist/app-registry/AppRegistryDapp.d.ts.map +1 -0
- package/dist/app-registry/AppRegistryDapp.js +182 -0
- package/dist/app-registry/AppRegistryDapp.js.map +1 -0
- package/dist/app-registry/IAppFactoryShim.d.ts +9 -0
- package/dist/app-registry/IAppFactoryShim.d.ts.map +1 -0
- package/dist/app-registry/IAppFactoryShim.js +9 -0
- package/dist/app-registry/IAppFactoryShim.js.map +1 -0
- package/dist/app-registry/IAppInstallerShim.d.ts +9 -0
- package/dist/app-registry/IAppInstallerShim.d.ts.map +1 -0
- package/dist/app-registry/IAppInstallerShim.js +9 -0
- package/dist/app-registry/IAppInstallerShim.js.map +1 -0
- package/dist/app-registry/IAppRegistryShim.d.ts +9 -0
- package/dist/app-registry/IAppRegistryShim.d.ts.map +1 -0
- package/dist/app-registry/IAppRegistryShim.js +9 -0
- package/dist/app-registry/IAppRegistryShim.js.map +1 -0
- package/dist/app-registry/IIdentityRegistryShim.d.ts +9 -0
- package/dist/app-registry/IIdentityRegistryShim.d.ts.map +1 -0
- package/dist/app-registry/IIdentityRegistryShim.js +9 -0
- package/dist/app-registry/IIdentityRegistryShim.js.map +1 -0
- package/dist/app-registry/IReputationRegistryShim.d.ts +9 -0
- package/dist/app-registry/IReputationRegistryShim.d.ts.map +1 -0
- package/dist/app-registry/IReputationRegistryShim.js +9 -0
- package/dist/app-registry/IReputationRegistryShim.js.map +1 -0
- package/dist/app-registry/SimpleAppShim.d.ts +9 -0
- package/dist/app-registry/SimpleAppShim.d.ts.map +1 -0
- package/dist/app-registry/SimpleAppShim.js +9 -0
- package/dist/app-registry/SimpleAppShim.js.map +1 -0
- package/dist/base-registry/BaseRegistry.d.ts +32 -0
- package/dist/base-registry/BaseRegistry.d.ts.map +1 -0
- package/dist/base-registry/BaseRegistry.js +67 -0
- package/dist/base-registry/BaseRegistry.js.map +1 -0
- package/dist/base-registry/IEntitlementCheckerShim.d.ts +9 -0
- package/dist/base-registry/IEntitlementCheckerShim.d.ts.map +1 -0
- package/dist/base-registry/IEntitlementCheckerShim.js +9 -0
- package/dist/base-registry/IEntitlementCheckerShim.js.map +1 -0
- package/dist/base-registry/INodeOperatorShim.d.ts +9 -0
- package/dist/base-registry/INodeOperatorShim.d.ts.map +1 -0
- package/dist/base-registry/INodeOperatorShim.js +9 -0
- package/dist/base-registry/INodeOperatorShim.js.map +1 -0
- package/dist/base-registry/ISpaceDelegationShim.d.ts +9 -0
- package/dist/base-registry/ISpaceDelegationShim.d.ts.map +1 -0
- package/dist/base-registry/ISpaceDelegationShim.js +9 -0
- package/dist/base-registry/ISpaceDelegationShim.js.map +1 -0
- package/dist/base-registry/RewardsDistributionShim.d.ts +9 -0
- package/dist/base-registry/RewardsDistributionShim.d.ts.map +1 -0
- package/dist/base-registry/RewardsDistributionShim.js +9 -0
- package/dist/base-registry/RewardsDistributionShim.js.map +1 -0
- package/dist/cache/EntitlementCache.d.ts +25 -0
- package/dist/cache/EntitlementCache.d.ts.map +1 -0
- package/dist/cache/EntitlementCache.js +91 -0
- package/dist/cache/EntitlementCache.js.map +1 -0
- package/dist/cache/ICacheStorage.d.ts +44 -0
- package/dist/cache/ICacheStorage.d.ts.map +1 -0
- package/dist/cache/ICacheStorage.js +2 -0
- package/dist/cache/ICacheStorage.js.map +1 -0
- package/dist/cache/KVCacheStorage.d.ts +79 -0
- package/dist/cache/KVCacheStorage.d.ts.map +1 -0
- package/dist/cache/KVCacheStorage.js +227 -0
- package/dist/cache/KVCacheStorage.js.map +1 -0
- package/dist/cache/Keyable.d.ts +20 -0
- package/dist/cache/Keyable.d.ts.map +1 -0
- package/dist/cache/Keyable.js +62 -0
- package/dist/cache/Keyable.js.map +1 -0
- package/dist/cache/SimpleCache.d.ts +30 -0
- package/dist/cache/SimpleCache.d.ts.map +1 -0
- package/dist/cache/SimpleCache.js +84 -0
- package/dist/cache/SimpleCache.js.map +1 -0
- package/dist/cache/TTLCacheStorage.d.ts +19 -0
- package/dist/cache/TTLCacheStorage.d.ts.map +1 -0
- package/dist/cache/TTLCacheStorage.js +40 -0
- package/dist/cache/TTLCacheStorage.js.map +1 -0
- package/dist/chain.d.ts +89 -0
- package/dist/chain.d.ts.map +1 -0
- package/dist/chain.js +48 -0
- package/dist/chain.js.map +1 -0
- package/dist/delegate-registry/DelegateRegistry.d.ts +3 -0
- package/dist/delegate-registry/DelegateRegistry.d.ts.map +1 -0
- package/dist/delegate-registry/DelegateRegistry.js +72 -0
- package/dist/delegate-registry/DelegateRegistry.js.map +1 -0
- package/dist/eip-712/EIP-712.d.ts +35 -0
- package/dist/eip-712/EIP-712.d.ts.map +1 -0
- package/dist/eip-712/EIP-712.js +57 -0
- package/dist/eip-712/EIP-712.js.map +1 -0
- package/dist/erc-721/IERC721AQueryableShim.d.ts +9 -0
- package/dist/erc-721/IERC721AQueryableShim.d.ts.map +1 -0
- package/dist/erc-721/IERC721AQueryableShim.js +9 -0
- package/dist/erc-721/IERC721AQueryableShim.js.map +1 -0
- package/dist/erc-721/IERC721AShim.d.ts +9 -0
- package/dist/erc-721/IERC721AShim.d.ts.map +1 -0
- package/dist/erc-721/IERC721AShim.js +9 -0
- package/dist/erc-721/IERC721AShim.js.map +1 -0
- package/dist/index.d.ts +96 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +96 -0
- package/dist/index.js.map +1 -0
- package/dist/platform-requirements/PlatformRequirements.d.ts +12 -0
- package/dist/platform-requirements/PlatformRequirements.d.ts.map +1 -0
- package/dist/platform-requirements/PlatformRequirements.js +18 -0
- package/dist/platform-requirements/PlatformRequirements.js.map +1 -0
- package/dist/pricing-modules/IPricingShim.d.ts +9 -0
- package/dist/pricing-modules/IPricingShim.d.ts.map +1 -0
- package/dist/pricing-modules/IPricingShim.js +9 -0
- package/dist/pricing-modules/IPricingShim.js.map +1 -0
- package/dist/pricing-modules/PricingModules.d.ts +13 -0
- package/dist/pricing-modules/PricingModules.d.ts.map +1 -0
- package/dist/pricing-modules/PricingModules.js +23 -0
- package/dist/pricing-modules/PricingModules.js.map +1 -0
- package/dist/pricing-modules/helpers.d.ts +16 -0
- package/dist/pricing-modules/helpers.d.ts.map +1 -0
- package/dist/pricing-modules/helpers.js +35 -0
- package/dist/pricing-modules/helpers.js.map +1 -0
- package/dist/readContractRetryer.d.ts +10 -0
- package/dist/readContractRetryer.d.ts.map +1 -0
- package/dist/readContractRetryer.js +68 -0
- package/dist/readContractRetryer.js.map +1 -0
- package/dist/river-registry/INodeRegistryShim.d.ts +9 -0
- package/dist/river-registry/INodeRegistryShim.d.ts.map +1 -0
- package/dist/river-registry/INodeRegistryShim.js +9 -0
- package/dist/river-registry/INodeRegistryShim.js.map +1 -0
- package/dist/river-registry/IOperatorRegistryShim.d.ts +9 -0
- package/dist/river-registry/IOperatorRegistryShim.d.ts.map +1 -0
- package/dist/river-registry/IOperatorRegistryShim.js +9 -0
- package/dist/river-registry/IOperatorRegistryShim.js.map +1 -0
- package/dist/river-registry/IStreamRegistryShim.d.ts +9 -0
- package/dist/river-registry/IStreamRegistryShim.d.ts.map +1 -0
- package/dist/river-registry/IStreamRegistryShim.js +9 -0
- package/dist/river-registry/IStreamRegistryShim.js.map +1 -0
- package/dist/river-registry/RiverRegistry.d.ts +18 -0
- package/dist/river-registry/RiverRegistry.d.ts.map +1 -0
- package/dist/river-registry/RiverRegistry.js +42 -0
- package/dist/river-registry/RiverRegistry.js.map +1 -0
- package/dist/river-registry/RiverRegistryFactory.d.ts +5 -0
- package/dist/river-registry/RiverRegistryFactory.d.ts.map +1 -0
- package/dist/river-registry/RiverRegistryFactory.js +5 -0
- package/dist/river-registry/RiverRegistryFactory.js.map +1 -0
- package/dist/space/IAppAccountShim.d.ts +9 -0
- package/dist/space/IAppAccountShim.d.ts.map +1 -0
- package/dist/space/IAppAccountShim.js +9 -0
- package/dist/space/IAppAccountShim.js.map +1 -0
- package/dist/space/IBanningShim.d.ts +9 -0
- package/dist/space/IBanningShim.d.ts.map +1 -0
- package/dist/space/IBanningShim.js +9 -0
- package/dist/space/IBanningShim.js.map +1 -0
- package/dist/space/IChannelShim.d.ts +9 -0
- package/dist/space/IChannelShim.d.ts.map +1 -0
- package/dist/space/IChannelShim.js +9 -0
- package/dist/space/IChannelShim.js.map +1 -0
- package/dist/space/IEntitlementDataQueryableShim.d.ts +11 -0
- package/dist/space/IEntitlementDataQueryableShim.d.ts.map +1 -0
- package/dist/space/IEntitlementDataQueryableShim.js +9 -0
- package/dist/space/IEntitlementDataQueryableShim.js.map +1 -0
- package/dist/space/IEntitlementsShim.d.ts +13 -0
- package/dist/space/IEntitlementsShim.d.ts.map +1 -0
- package/dist/space/IEntitlementsShim.js +19 -0
- package/dist/space/IEntitlementsShim.js.map +1 -0
- package/dist/space/IMembershipMetadataShim.d.ts +9 -0
- package/dist/space/IMembershipMetadataShim.d.ts.map +1 -0
- package/dist/space/IMembershipMetadataShim.js +9 -0
- package/dist/space/IMembershipMetadataShim.js.map +1 -0
- package/dist/space/IMembershipShim.d.ts +33 -0
- package/dist/space/IMembershipShim.d.ts.map +1 -0
- package/dist/space/IMembershipShim.js +139 -0
- package/dist/space/IMembershipShim.js.map +1 -0
- package/dist/space/IMulticallShim.d.ts +13 -0
- package/dist/space/IMulticallShim.d.ts.map +1 -0
- package/dist/space/IMulticallShim.js +15 -0
- package/dist/space/IMulticallShim.js.map +1 -0
- package/dist/space/IReviewShim.d.ts +64 -0
- package/dist/space/IReviewShim.d.ts.map +1 -0
- package/dist/space/IReviewShim.js +102 -0
- package/dist/space/IReviewShim.js.map +1 -0
- package/dist/space/IRolesShim.d.ts +10 -0
- package/dist/space/IRolesShim.d.ts.map +1 -0
- package/dist/space/IRolesShim.js +9 -0
- package/dist/space/IRolesShim.js.map +1 -0
- package/dist/space/ITippingShim.d.ts +39 -0
- package/dist/space/ITippingShim.d.ts.map +1 -0
- package/dist/space/ITippingShim.js +76 -0
- package/dist/space/ITippingShim.js.map +1 -0
- package/dist/space/ITreasuryShim.d.ts +9 -0
- package/dist/space/ITreasuryShim.d.ts.map +1 -0
- package/dist/space/ITreasuryShim.js +9 -0
- package/dist/space/ITreasuryShim.js.map +1 -0
- package/dist/space/OwnableFacetShim.d.ts +12 -0
- package/dist/space/OwnableFacetShim.d.ts.map +1 -0
- package/dist/space/OwnableFacetShim.js +19 -0
- package/dist/space/OwnableFacetShim.js.map +1 -0
- package/dist/space/Space.d.ts +107 -0
- package/dist/space/Space.d.ts.map +1 -0
- package/dist/space/Space.js +511 -0
- package/dist/space/Space.js.map +1 -0
- package/dist/space/TokenPausableFacetShim.d.ts +9 -0
- package/dist/space/TokenPausableFacetShim.d.ts.map +1 -0
- package/dist/space/TokenPausableFacetShim.js +9 -0
- package/dist/space/TokenPausableFacetShim.js.map +1 -0
- package/dist/space/entitlements/ConvertersEntitlements.d.ts +14 -0
- package/dist/space/entitlements/ConvertersEntitlements.d.ts.map +1 -0
- package/dist/space/entitlements/ConvertersEntitlements.js +193 -0
- package/dist/space/entitlements/ConvertersEntitlements.js.map +1 -0
- package/dist/space/entitlements/RuleBuilder.d.ts +83 -0
- package/dist/space/entitlements/RuleBuilder.d.ts.map +1 -0
- package/dist/space/entitlements/RuleBuilder.js +86 -0
- package/dist/space/entitlements/RuleBuilder.js.map +1 -0
- package/dist/space/entitlements/RuleEntitlementShim.d.ts +353 -0
- package/dist/space/entitlements/RuleEntitlementShim.d.ts.map +1 -0
- package/dist/space/entitlements/RuleEntitlementShim.js +40 -0
- package/dist/space/entitlements/RuleEntitlementShim.js.map +1 -0
- package/dist/space/entitlements/RuleEntitlementV2Shim.d.ts +353 -0
- package/dist/space/entitlements/RuleEntitlementV2Shim.d.ts.map +1 -0
- package/dist/space/entitlements/RuleEntitlementV2Shim.js +40 -0
- package/dist/space/entitlements/RuleEntitlementV2Shim.js.map +1 -0
- package/dist/space/entitlements/UserEntitlementShim.d.ts +13 -0
- package/dist/space/entitlements/UserEntitlementShim.d.ts.map +1 -0
- package/dist/space/entitlements/UserEntitlementShim.js +45 -0
- package/dist/space/entitlements/UserEntitlementShim.js.map +1 -0
- package/dist/space/entitlements/XChainConfig.d.ts +14 -0
- package/dist/space/entitlements/XChainConfig.d.ts.map +1 -0
- package/dist/space/entitlements/XChainConfig.js +70 -0
- package/dist/space/entitlements/XChainConfig.js.map +1 -0
- package/dist/space/entitlements/entitlement.d.ts +147 -0
- package/dist/space/entitlements/entitlement.d.ts.map +1 -0
- package/dist/space/entitlements/entitlement.js +940 -0
- package/dist/space/entitlements/entitlement.js.map +1 -0
- package/dist/space/entitlements/validateAndParseXChainConfig.d.ts +6 -0
- package/dist/space/entitlements/validateAndParseXChainConfig.d.ts.map +1 -0
- package/dist/space/entitlements/validateAndParseXChainConfig.js +34 -0
- package/dist/space/entitlements/validateAndParseXChainConfig.js.map +1 -0
- package/dist/space-dapp/SpaceDapp.d.ts +223 -0
- package/dist/space-dapp/SpaceDapp.d.ts.map +1 -0
- package/dist/space-dapp/SpaceDapp.js +1260 -0
- package/dist/space-dapp/SpaceDapp.js.map +1 -0
- package/dist/space-dapp/SpaceDappFactory.d.ts +5 -0
- package/dist/space-dapp/SpaceDappFactory.d.ts.map +1 -0
- package/dist/space-dapp/SpaceDappFactory.js +8 -0
- package/dist/space-dapp/SpaceDappFactory.js.map +1 -0
- package/dist/space-dapp/wrapTransaction.d.ts +4 -0
- package/dist/space-dapp/wrapTransaction.d.ts.map +1 -0
- package/dist/space-dapp/wrapTransaction.js +99 -0
- package/dist/space-dapp/wrapTransaction.js.map +1 -0
- package/dist/space-owner/GuardianFacetShim.d.ts +9 -0
- package/dist/space-owner/GuardianFacetShim.d.ts.map +1 -0
- package/dist/space-owner/GuardianFacetShim.js +9 -0
- package/dist/space-owner/GuardianFacetShim.js.map +1 -0
- package/dist/space-owner/SpaceOwner.d.ts +48 -0
- package/dist/space-owner/SpaceOwner.d.ts.map +1 -0
- package/dist/space-owner/SpaceOwner.js +81 -0
- package/dist/space-owner/SpaceOwner.js.map +1 -0
- package/dist/space-registrar/ICreateSpaceShim.d.ts +11 -0
- package/dist/space-registrar/ICreateSpaceShim.d.ts.map +1 -0
- package/dist/space-registrar/ICreateSpaceShim.js +9 -0
- package/dist/space-registrar/ICreateSpaceShim.js.map +1 -0
- package/dist/space-registrar/ILegacySpaceArchitectShim.d.ts +10 -0
- package/dist/space-registrar/ILegacySpaceArchitectShim.d.ts.map +1 -0
- package/dist/space-registrar/ILegacySpaceArchitectShim.js +9 -0
- package/dist/space-registrar/ILegacySpaceArchitectShim.js.map +1 -0
- package/dist/space-registrar/ISpaceArchitectShim.d.ts +10 -0
- package/dist/space-registrar/ISpaceArchitectShim.d.ts.map +1 -0
- package/dist/space-registrar/ISpaceArchitectShim.js +39 -0
- package/dist/space-registrar/ISpaceArchitectShim.js.map +1 -0
- package/dist/space-registrar/SpaceRegistrar.d.ts +27 -0
- package/dist/space-registrar/SpaceRegistrar.d.ts.map +1 -0
- package/dist/space-registrar/SpaceRegistrar.js +58 -0
- package/dist/space-registrar/SpaceRegistrar.js.map +1 -0
- package/dist/test-helpers/LocalhostWeb3Provider.d.ts +19 -0
- package/dist/test-helpers/LocalhostWeb3Provider.d.ts.map +1 -0
- package/dist/test-helpers/LocalhostWeb3Provider.js +80 -0
- package/dist/test-helpers/LocalhostWeb3Provider.js.map +1 -0
- package/dist/test-helpers/MockCrossChainEntitlement.d.ts +6 -0
- package/dist/test-helpers/MockCrossChainEntitlement.d.ts.map +1 -0
- package/dist/test-helpers/MockCrossChainEntitlement.js +104 -0
- package/dist/test-helpers/MockCrossChainEntitlement.js.map +1 -0
- package/dist/test-helpers/MockERC1155.d.ts +6 -0
- package/dist/test-helpers/MockERC1155.d.ts.map +1 -0
- package/dist/test-helpers/MockERC1155.js +518 -0
- package/dist/test-helpers/MockERC1155.js.map +1 -0
- package/dist/test-helpers/MockERC20.d.ts +6 -0
- package/dist/test-helpers/MockERC20.d.ts.map +1 -0
- package/dist/test-helpers/MockERC20.js +574 -0
- package/dist/test-helpers/MockERC20.js.map +1 -0
- package/dist/test-helpers/MockERC721A.d.ts +1563 -0
- package/dist/test-helpers/MockERC721A.d.ts.map +1 -0
- package/dist/test-helpers/MockERC721A.js +1913 -0
- package/dist/test-helpers/MockERC721A.js.map +1 -0
- package/dist/test-helpers/MockERC721AShim.d.ts +9 -0
- package/dist/test-helpers/MockERC721AShim.d.ts.map +1 -0
- package/dist/test-helpers/MockERC721AShim.js +9 -0
- package/dist/test-helpers/MockERC721AShim.js.map +1 -0
- package/dist/test-helpers/TestCrossChainEntitlement.d.ts +14 -0
- package/dist/test-helpers/TestCrossChainEntitlement.d.ts.map +1 -0
- package/dist/test-helpers/TestCrossChainEntitlement.js +99 -0
- package/dist/test-helpers/TestCrossChainEntitlement.js.map +1 -0
- package/dist/test-helpers/TestEthBalance.d.ts +72 -0
- package/dist/test-helpers/TestEthBalance.d.ts.map +1 -0
- package/dist/test-helpers/TestEthBalance.js +94 -0
- package/dist/test-helpers/TestEthBalance.js.map +1 -0
- package/dist/test-helpers/TestGatingERC1155.d.ts +17 -0
- package/dist/test-helpers/TestGatingERC1155.d.ts.map +1 -0
- package/dist/test-helpers/TestGatingERC1155.js +100 -0
- package/dist/test-helpers/TestGatingERC1155.js.map +1 -0
- package/dist/test-helpers/TestGatingERC20.d.ts +17 -0
- package/dist/test-helpers/TestGatingERC20.d.ts.map +1 -0
- package/dist/test-helpers/TestGatingERC20.js +149 -0
- package/dist/test-helpers/TestGatingERC20.js.map +1 -0
- package/dist/test-helpers/TestGatingNFT.d.ts +17 -0
- package/dist/test-helpers/TestGatingNFT.d.ts.map +1 -0
- package/dist/test-helpers/TestGatingNFT.js +137 -0
- package/dist/test-helpers/TestGatingNFT.js.map +1 -0
- package/dist/test-helpers/TestGatingUtils.d.ts +15 -0
- package/dist/test-helpers/TestGatingUtils.d.ts.map +1 -0
- package/dist/test-helpers/TestGatingUtils.js +112 -0
- package/dist/test-helpers/TestGatingUtils.js.map +1 -0
- package/dist/test-helpers/utils.d.ts +22 -0
- package/dist/test-helpers/utils.d.ts.map +1 -0
- package/dist/test-helpers/utils.js +30 -0
- package/dist/test-helpers/utils.js.map +1 -0
- package/dist/towns-token/TownsToken.d.ts +17 -0
- package/dist/towns-token/TownsToken.d.ts.map +1 -0
- package/dist/towns-token/TownsToken.js +33 -0
- package/dist/towns-token/TownsToken.js.map +1 -0
- package/dist/types/ContractTypes.d.ts +240 -0
- package/dist/types/ContractTypes.d.ts.map +1 -0
- package/dist/types/ContractTypes.js +65 -0
- package/dist/types/ContractTypes.js.map +1 -0
- package/dist/types/error-types.d.ts +7 -0
- package/dist/types/error-types.d.ts.map +1 -0
- package/dist/types/error-types.js +13 -0
- package/dist/types/error-types.js.map +1 -0
- package/dist/types/typechain.d.ts +4 -0
- package/dist/types/typechain.d.ts.map +1 -0
- package/dist/types/typechain.js +2 -0
- package/dist/types/typechain.js.map +1 -0
- package/dist/types/types.d.ts +29 -0
- package/dist/types/types.d.ts.map +1 -0
- package/dist/types/types.js +2 -0
- package/dist/types/types.js.map +1 -0
- package/dist/utils/ContractHelpers.d.ts +14 -0
- package/dist/utils/ContractHelpers.d.ts.map +1 -0
- package/dist/utils/ContractHelpers.js +54 -0
- package/dist/utils/ContractHelpers.js.map +1 -0
- package/dist/utils/Web3Constants.d.ts +6 -0
- package/dist/utils/Web3Constants.d.ts.map +1 -0
- package/dist/utils/Web3Constants.js +7 -0
- package/dist/utils/Web3Constants.js.map +1 -0
- package/dist/utils/ut.d.ts +46 -0
- package/dist/utils/ut.d.ts.map +1 -0
- package/dist/utils/ut.js +94 -0
- package/dist/utils/ut.js.map +1 -0
- package/dist/utils/web3Env.d.ts +36 -0
- package/dist/utils/web3Env.d.ts.map +1 -0
- package/dist/utils/web3Env.js +123 -0
- package/dist/utils/web3Env.js.map +1 -0
- package/dist/wallet-link/WalletLink.d.ts +58 -0
- package/dist/wallet-link/WalletLink.d.ts.map +1 -0
- package/dist/wallet-link/WalletLink.js +226 -0
- package/dist/wallet-link/WalletLink.js.map +1 -0
- package/dist/wallet-link/WalletLinkShim.d.ts +9 -0
- package/dist/wallet-link/WalletLinkShim.d.ts.map +1 -0
- package/dist/wallet-link/WalletLinkShim.js +9 -0
- package/dist/wallet-link/WalletLinkShim.js.map +1 -0
- package/package.json +50 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**************************************************************************
|
|
2
|
+
* This file is generated by running 🏕️ scripts/generate_sdk_index.sh 🏕️ *
|
|
3
|
+
**************************************************************************/
|
|
4
|
+
export * from './BaseContractShim';
|
|
5
|
+
export * from './airdrop/IDropFacetShim';
|
|
6
|
+
export * from './airdrop/IRiverPointsShim';
|
|
7
|
+
export * from './airdrop/RiverAirdropDapp';
|
|
8
|
+
export * from './app-registry/AppRegistryDapp';
|
|
9
|
+
export * from './app-registry/IAppFactoryShim';
|
|
10
|
+
export * from './app-registry/IAppInstallerShim';
|
|
11
|
+
export * from './app-registry/IAppRegistryShim';
|
|
12
|
+
export * from './app-registry/IIdentityRegistryShim';
|
|
13
|
+
export * from './app-registry/IReputationRegistryShim';
|
|
14
|
+
export * from './app-registry/SimpleAppShim';
|
|
15
|
+
export * from './base-registry/BaseRegistry';
|
|
16
|
+
export * from './base-registry/IEntitlementCheckerShim';
|
|
17
|
+
export * from './base-registry/INodeOperatorShim';
|
|
18
|
+
export * from './base-registry/ISpaceDelegationShim';
|
|
19
|
+
export * from './base-registry/RewardsDistributionShim';
|
|
20
|
+
export * from './cache/EntitlementCache';
|
|
21
|
+
export * from './cache/ICacheStorage';
|
|
22
|
+
export * from './cache/Keyable';
|
|
23
|
+
export * from './cache/KVCacheStorage';
|
|
24
|
+
export * from './cache/SimpleCache';
|
|
25
|
+
export * from './cache/TTLCacheStorage';
|
|
26
|
+
export * from './chain';
|
|
27
|
+
export * from './delegate-registry/DelegateRegistry';
|
|
28
|
+
export * from './eip-712/EIP-712';
|
|
29
|
+
export * from './erc-721/IERC721AQueryableShim';
|
|
30
|
+
export * from './erc-721/IERC721AShim';
|
|
31
|
+
export * from './platform-requirements/PlatformRequirements';
|
|
32
|
+
export * from './pricing-modules/IPricingShim';
|
|
33
|
+
export * from './pricing-modules/PricingModules';
|
|
34
|
+
export * from './pricing-modules/helpers';
|
|
35
|
+
export * from './readContractRetryer';
|
|
36
|
+
export * from './river-registry/IOperatorRegistryShim';
|
|
37
|
+
export * from './river-registry/IStreamRegistryShim';
|
|
38
|
+
export * from './river-registry/RiverRegistry';
|
|
39
|
+
export * from './river-registry/RiverRegistryFactory';
|
|
40
|
+
export * from './space-dapp/SpaceDapp';
|
|
41
|
+
export * from './space-dapp/SpaceDappFactory';
|
|
42
|
+
export * from './space-dapp/wrapTransaction';
|
|
43
|
+
export * from './space-owner/GuardianFacetShim';
|
|
44
|
+
export * from './space-owner/SpaceOwner';
|
|
45
|
+
export * from './space-registrar/ICreateSpaceShim';
|
|
46
|
+
export * from './space-registrar/ILegacySpaceArchitectShim';
|
|
47
|
+
export * from './space-registrar/ISpaceArchitectShim';
|
|
48
|
+
export * from './space-registrar/SpaceRegistrar';
|
|
49
|
+
export * from './space/IAppAccountShim';
|
|
50
|
+
export * from './space/IBanningShim';
|
|
51
|
+
export * from './space/IChannelShim';
|
|
52
|
+
export * from './space/IEntitlementDataQueryableShim';
|
|
53
|
+
export * from './space/IEntitlementsShim';
|
|
54
|
+
export * from './space/IMembershipMetadataShim';
|
|
55
|
+
export * from './space/IMembershipShim';
|
|
56
|
+
export * from './space/IMulticallShim';
|
|
57
|
+
export * from './space/IReviewShim';
|
|
58
|
+
export * from './space/IRolesShim';
|
|
59
|
+
export * from './space/ITippingShim';
|
|
60
|
+
export * from './space/ITreasuryShim';
|
|
61
|
+
export * from './space/OwnableFacetShim';
|
|
62
|
+
export * from './space/Space';
|
|
63
|
+
export * from './space/TokenPausableFacetShim';
|
|
64
|
+
export * from './space/entitlements/ConvertersEntitlements';
|
|
65
|
+
export * from './space/entitlements/RuleBuilder';
|
|
66
|
+
export * from './space/entitlements/RuleEntitlementShim';
|
|
67
|
+
export * from './space/entitlements/RuleEntitlementV2Shim';
|
|
68
|
+
export * from './space/entitlements/UserEntitlementShim';
|
|
69
|
+
export * from './space/entitlements/entitlement';
|
|
70
|
+
export * from './space/entitlements/XChainConfig';
|
|
71
|
+
export * from './space/entitlements/validateAndParseXChainConfig';
|
|
72
|
+
export * from './test-helpers/LocalhostWeb3Provider';
|
|
73
|
+
export * from './test-helpers/MockCrossChainEntitlement';
|
|
74
|
+
export * from './test-helpers/MockERC1155';
|
|
75
|
+
export * from './test-helpers/MockERC20';
|
|
76
|
+
export * from './test-helpers/MockERC721A';
|
|
77
|
+
export * from './test-helpers/MockERC721AShim';
|
|
78
|
+
export * from './test-helpers/TestCrossChainEntitlement';
|
|
79
|
+
export * from './test-helpers/TestEthBalance';
|
|
80
|
+
export * from './test-helpers/TestGatingERC1155';
|
|
81
|
+
export * from './test-helpers/TestGatingERC20';
|
|
82
|
+
export * from './test-helpers/TestGatingNFT';
|
|
83
|
+
export * from './test-helpers/TestGatingUtils';
|
|
84
|
+
export * from './test-helpers/utils';
|
|
85
|
+
export * from './towns-token/TownsToken';
|
|
86
|
+
export * from './types/ContractTypes';
|
|
87
|
+
export * from './types/error-types';
|
|
88
|
+
export * from './types/typechain';
|
|
89
|
+
export * from './types/types';
|
|
90
|
+
export * from './utils/ContractHelpers';
|
|
91
|
+
export * from './utils/Web3Constants';
|
|
92
|
+
export * from './utils/ut';
|
|
93
|
+
export * from './utils/web3Env';
|
|
94
|
+
export * from './wallet-link/WalletLink';
|
|
95
|
+
export * from './wallet-link/WalletLinkShim';
|
|
96
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;4EAE4E;AAC5E,cAAc,oBAAoB,CAAA;AAClC,cAAc,0BAA0B,CAAA;AACxC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,kCAAkC,CAAA;AAChD,cAAc,iCAAiC,CAAA;AAC/C,cAAc,sCAAsC,CAAA;AACpD,cAAc,wCAAwC,CAAA;AACtD,cAAc,8BAA8B,CAAA;AAC5C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,yCAAyC,CAAA;AACvD,cAAc,mCAAmC,CAAA;AACjD,cAAc,sCAAsC,CAAA;AACpD,cAAc,yCAAyC,CAAA;AACvD,cAAc,0BAA0B,CAAA;AACxC,cAAc,uBAAuB,CAAA;AACrC,cAAc,iBAAiB,CAAA;AAC/B,cAAc,wBAAwB,CAAA;AACtC,cAAc,qBAAqB,CAAA;AACnC,cAAc,yBAAyB,CAAA;AACvC,cAAc,SAAS,CAAA;AACvB,cAAc,sCAAsC,CAAA;AACpD,cAAc,mBAAmB,CAAA;AACjC,cAAc,iCAAiC,CAAA;AAC/C,cAAc,wBAAwB,CAAA;A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C1C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,0CAA0C,CAAA;AACxD,cAAc,+BAA+B,CAAA;AAC7C,cAAc,kCAAkC,CAAA;AAChD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,sBAAsB,CAAA;AACpC,cAAc,0BAA0B,CAAA;AACxC,cAAc,uBAAuB,CAAA;AACrC,cAAc,qBAAqB,CAAA;AACnC,cAAc,mBAAmB,CAAA;AACjC,cAAc,eAAe,CAAA;AAC7B,cAAc,yBAAyB,CAAA;AACvC,cAAc,uBAAuB,CAAA;AACrC,cAAc,YAAY,CAAA;AAC1B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,0BAA0B,CAAA;AACxC,cAAc,8BAA8B,CAAA"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**************************************************************************
|
|
2
|
+
* This file is generated by running 🏕️ scripts/generate_sdk_index.sh 🏕️ *
|
|
3
|
+
**************************************************************************/
|
|
4
|
+
export * from './BaseContractShim';
|
|
5
|
+
export * from './airdrop/IDropFacetShim';
|
|
6
|
+
export * from './airdrop/IRiverPointsShim';
|
|
7
|
+
export * from './airdrop/RiverAirdropDapp';
|
|
8
|
+
export * from './app-registry/AppRegistryDapp';
|
|
9
|
+
export * from './app-registry/IAppFactoryShim';
|
|
10
|
+
export * from './app-registry/IAppInstallerShim';
|
|
11
|
+
export * from './app-registry/IAppRegistryShim';
|
|
12
|
+
export * from './app-registry/IIdentityRegistryShim';
|
|
13
|
+
export * from './app-registry/IReputationRegistryShim';
|
|
14
|
+
export * from './app-registry/SimpleAppShim';
|
|
15
|
+
export * from './base-registry/BaseRegistry';
|
|
16
|
+
export * from './base-registry/IEntitlementCheckerShim';
|
|
17
|
+
export * from './base-registry/INodeOperatorShim';
|
|
18
|
+
export * from './base-registry/ISpaceDelegationShim';
|
|
19
|
+
export * from './base-registry/RewardsDistributionShim';
|
|
20
|
+
export * from './cache/EntitlementCache';
|
|
21
|
+
export * from './cache/ICacheStorage';
|
|
22
|
+
export * from './cache/Keyable';
|
|
23
|
+
export * from './cache/KVCacheStorage';
|
|
24
|
+
export * from './cache/SimpleCache';
|
|
25
|
+
export * from './cache/TTLCacheStorage';
|
|
26
|
+
export * from './chain';
|
|
27
|
+
export * from './delegate-registry/DelegateRegistry';
|
|
28
|
+
export * from './eip-712/EIP-712';
|
|
29
|
+
export * from './erc-721/IERC721AQueryableShim';
|
|
30
|
+
export * from './erc-721/IERC721AShim';
|
|
31
|
+
export * from './platform-requirements/PlatformRequirements';
|
|
32
|
+
export * from './pricing-modules/IPricingShim';
|
|
33
|
+
export * from './pricing-modules/PricingModules';
|
|
34
|
+
export * from './pricing-modules/helpers';
|
|
35
|
+
export * from './readContractRetryer';
|
|
36
|
+
export * from './river-registry/IOperatorRegistryShim';
|
|
37
|
+
export * from './river-registry/IStreamRegistryShim';
|
|
38
|
+
export * from './river-registry/RiverRegistry';
|
|
39
|
+
export * from './river-registry/RiverRegistryFactory';
|
|
40
|
+
export * from './space-dapp/SpaceDapp';
|
|
41
|
+
export * from './space-dapp/SpaceDappFactory';
|
|
42
|
+
export * from './space-dapp/wrapTransaction';
|
|
43
|
+
export * from './space-owner/GuardianFacetShim';
|
|
44
|
+
export * from './space-owner/SpaceOwner';
|
|
45
|
+
export * from './space-registrar/ICreateSpaceShim';
|
|
46
|
+
export * from './space-registrar/ILegacySpaceArchitectShim';
|
|
47
|
+
export * from './space-registrar/ISpaceArchitectShim';
|
|
48
|
+
export * from './space-registrar/SpaceRegistrar';
|
|
49
|
+
export * from './space/IAppAccountShim';
|
|
50
|
+
export * from './space/IBanningShim';
|
|
51
|
+
export * from './space/IChannelShim';
|
|
52
|
+
export * from './space/IEntitlementDataQueryableShim';
|
|
53
|
+
export * from './space/IEntitlementsShim';
|
|
54
|
+
export * from './space/IMembershipMetadataShim';
|
|
55
|
+
export * from './space/IMembershipShim';
|
|
56
|
+
export * from './space/IMulticallShim';
|
|
57
|
+
export * from './space/IReviewShim';
|
|
58
|
+
export * from './space/IRolesShim';
|
|
59
|
+
export * from './space/ITippingShim';
|
|
60
|
+
export * from './space/ITreasuryShim';
|
|
61
|
+
export * from './space/OwnableFacetShim';
|
|
62
|
+
export * from './space/Space';
|
|
63
|
+
export * from './space/TokenPausableFacetShim';
|
|
64
|
+
export * from './space/entitlements/ConvertersEntitlements';
|
|
65
|
+
export * from './space/entitlements/RuleBuilder';
|
|
66
|
+
export * from './space/entitlements/RuleEntitlementShim';
|
|
67
|
+
export * from './space/entitlements/RuleEntitlementV2Shim';
|
|
68
|
+
export * from './space/entitlements/UserEntitlementShim';
|
|
69
|
+
export * from './space/entitlements/entitlement';
|
|
70
|
+
export * from './space/entitlements/XChainConfig';
|
|
71
|
+
export * from './space/entitlements/validateAndParseXChainConfig';
|
|
72
|
+
export * from './test-helpers/LocalhostWeb3Provider';
|
|
73
|
+
export * from './test-helpers/MockCrossChainEntitlement';
|
|
74
|
+
export * from './test-helpers/MockERC1155';
|
|
75
|
+
export * from './test-helpers/MockERC20';
|
|
76
|
+
export * from './test-helpers/MockERC721A';
|
|
77
|
+
export * from './test-helpers/MockERC721AShim';
|
|
78
|
+
export * from './test-helpers/TestCrossChainEntitlement';
|
|
79
|
+
export * from './test-helpers/TestEthBalance';
|
|
80
|
+
export * from './test-helpers/TestGatingERC1155';
|
|
81
|
+
export * from './test-helpers/TestGatingERC20';
|
|
82
|
+
export * from './test-helpers/TestGatingNFT';
|
|
83
|
+
export * from './test-helpers/TestGatingUtils';
|
|
84
|
+
export * from './test-helpers/utils';
|
|
85
|
+
export * from './towns-token/TownsToken';
|
|
86
|
+
export * from './types/ContractTypes';
|
|
87
|
+
export * from './types/error-types';
|
|
88
|
+
export * from './types/typechain';
|
|
89
|
+
export * from './types/types';
|
|
90
|
+
export * from './utils/ContractHelpers';
|
|
91
|
+
export * from './utils/Web3Constants';
|
|
92
|
+
export * from './utils/ut';
|
|
93
|
+
export * from './utils/web3Env';
|
|
94
|
+
export * from './wallet-link/WalletLink';
|
|
95
|
+
export * from './wallet-link/WalletLinkShim';
|
|
96
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;4EAE4E;AAC5E,cAAc,oBAAoB,CAAA;AAClC,cAAc,0BAA0B,CAAA;AACxC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,4BAA4B,CAAA;AAC1C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,gCAAgC,CAAA;AAC9C,cAAc,kCAAkC,CAAA;AAChD,cAAc,iCAAiC,CAAA;AAC/C,cAAc,sCAAsC,CAAA;AACpD,cAAc,wCAAwC,CAAA;AACtD,cAAc,8BAA8B,CAAA;AAC5C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,yCAAyC,CAAA;AACvD,cAAc,mCAAmC,CAAA;AACjD,cAAc,sCAAsC,CAAA;AACpD,cAAc,yCAAyC,CAAA;AACvD,cAAc,0BAA0B,CAAA;AACxC,cAAc,uBAAuB,CAAA;AACrC,cAAc,iBAAiB,CAAA;AAC/B,cAAc,wBAAwB,CAAA;AACtC,cAAc,qBAAqB,CAAA;AACnC,cAAc,yBAAyB,CAAA;AACvC,cAAc,SAAS,CAAA;AACvB,cAAc,sCAAsC,CAAA;AACpD,cAAc,mBAAmB,CAAA;AACjC,cAAc,iCAAiC,CAAA;AAC/C,cAAc,wBAAwB,CAAA;AACtC,cAAc,8CAA8C,CAAA;AAC5D,cAAc,gCAAgC,CAAA;AAC9C,cAAc,kCAAkC,CAAA;AAChD,cAAc,2BAA2B,CAAA;AACzC,cAAc,uBAAuB,CAAA;AACrC,cAAc,wCAAwC,CAAA;AACtD,cAAc,sCAAsC,CAAA;AACpD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,uCAAuC,CAAA;AACrD,cAAc,wBAAwB,CAAA;AACtC,cAAc,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c,qBAAqB,CAAA;AACnC,cAAc,mBAAmB,CAAA;AACjC,cAAc,eAAe,CAAA;AAC7B,cAAc,yBAAyB,CAAA;AACvC,cAAc,uBAAuB,CAAA;AACrC,cAAc,YAAY,CAAA;AAC1B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,0BAA0B,CAAA;AACxC,cAAc,8BAA8B,CAAA"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
3
|
+
import { PlatformRequirementsFacet__factory } from '@towns-labs/generated/dev/typings/factories/PlatformRequirementsFacet__factory';
|
|
4
|
+
declare const connect: typeof PlatformRequirementsFacet__factory.connect;
|
|
5
|
+
export declare class PlatformRequirements extends BaseContractShim<typeof connect> {
|
|
6
|
+
constructor(address: string, provider: ethers.providers.Provider);
|
|
7
|
+
getMembershipMintLimit(): Promise<ethers.BigNumber>;
|
|
8
|
+
getMembershipFee(): Promise<ethers.BigNumber>;
|
|
9
|
+
getMembershipMinPrice(): Promise<ethers.BigNumber>;
|
|
10
|
+
}
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=PlatformRequirements.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PlatformRequirements.d.ts","sourceRoot":"","sources":["../../src/platform-requirements/PlatformRequirements.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,kCAAkC,EAAE,MAAM,gFAAgF,CAAA;AAEnI,QAAA,MAAa,OAAO,mDAAuC,CAAA;AAE3D,qBAAa,oBAAqB,SAAQ,gBAAgB,CAAC,OAAO,OAAO,CAAC;gBAC1D,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;IAIzD,sBAAsB;IAItB,gBAAgB;IAIhB,qBAAqB;CAG/B"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
2
|
+
import { PlatformRequirementsFacet__factory } from '@towns-labs/generated/dev/typings/factories/PlatformRequirementsFacet__factory';
|
|
3
|
+
const { abi, connect } = PlatformRequirementsFacet__factory;
|
|
4
|
+
export class PlatformRequirements extends BaseContractShim {
|
|
5
|
+
constructor(address, provider) {
|
|
6
|
+
super(address, provider, connect, abi);
|
|
7
|
+
}
|
|
8
|
+
getMembershipMintLimit() {
|
|
9
|
+
return this.read.getMembershipMintLimit();
|
|
10
|
+
}
|
|
11
|
+
getMembershipFee() {
|
|
12
|
+
return this.read.getMembershipFee();
|
|
13
|
+
}
|
|
14
|
+
getMembershipMinPrice() {
|
|
15
|
+
return this.read.getMembershipMinPrice();
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=PlatformRequirements.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PlatformRequirements.js","sourceRoot":"","sources":["../../src/platform-requirements/PlatformRequirements.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,kCAAkC,EAAE,MAAM,gFAAgF,CAAA;AAEnI,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,kCAAkC,CAAA;AAE3D,MAAM,OAAO,oBAAqB,SAAQ,gBAAgC;IACtE,YAAY,OAAe,EAAE,QAAmC;QAC5D,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAA;IAC1C,CAAC;IAEM,sBAAsB;QACzB,OAAO,IAAI,CAAC,IAAI,CAAC,sBAAsB,EAAE,CAAA;IAC7C,CAAC;IAEM,gBAAgB;QACnB,OAAO,IAAI,CAAC,IAAI,CAAC,gBAAgB,EAAE,CAAA;IACvC,CAAC;IAEM,qBAAqB;QACxB,OAAO,IAAI,CAAC,IAAI,CAAC,qBAAqB,EAAE,CAAA;IAC5C,CAAC;CACJ"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
3
|
+
import { IPricingModules__factory } from '@towns-labs/generated/dev/typings/factories/IPricingModules__factory';
|
|
4
|
+
declare const connect: typeof IPricingModules__factory.connect;
|
|
5
|
+
export type { IPricingModulesBase } from '@towns-labs/generated/dev/typings/IPricingModules';
|
|
6
|
+
export declare class IPricingShim extends BaseContractShim<typeof connect> {
|
|
7
|
+
constructor(address: string, provider: ethers.providers.Provider);
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=IPricingShim.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IPricingShim.d.ts","sourceRoot":"","sources":["../../src/pricing-modules/IPricingShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,wBAAwB,EAAE,MAAM,sEAAsE,CAAA;AAE/G,QAAA,MAAa,OAAO,yCAA6B,CAAA;AAEjD,YAAY,EAAE,mBAAmB,EAAE,MAAM,mDAAmD,CAAA;AAE5F,qBAAa,YAAa,SAAQ,gBAAgB,CAAC,OAAO,OAAO,CAAC;gBAClD,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;CAGnE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
2
|
+
import { IPricingModules__factory } from '@towns-labs/generated/dev/typings/factories/IPricingModules__factory';
|
|
3
|
+
const { abi, connect } = IPricingModules__factory;
|
|
4
|
+
export class IPricingShim extends BaseContractShim {
|
|
5
|
+
constructor(address, provider) {
|
|
6
|
+
super(address, provider, connect, abi);
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=IPricingShim.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IPricingShim.js","sourceRoot":"","sources":["../../src/pricing-modules/IPricingShim.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,wBAAwB,EAAE,MAAM,sEAAsE,CAAA;AAE/G,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,wBAAwB,CAAA;AAIjD,MAAM,OAAO,YAAa,SAAQ,gBAAgC;IAC9D,YAAY,OAAe,EAAE,QAAmC;QAC5D,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAA;IAC1C,CAAC;CACJ"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { BaseChainConfig } from '../utils/web3Env';
|
|
3
|
+
import { PricingModuleStruct } from '../types/ContractTypes';
|
|
4
|
+
export declare class PricingModules {
|
|
5
|
+
private readonly pricingShim;
|
|
6
|
+
constructor(config: BaseChainConfig, provider: ethers.providers.Provider);
|
|
7
|
+
parseError(error: unknown): Error;
|
|
8
|
+
listPricingModules(): Promise<PricingModuleStruct[]>;
|
|
9
|
+
addPricingModule(moduleAddress: string, signer: ethers.Signer): Promise<void>;
|
|
10
|
+
removePricingModule(moduleAddress: string, signer: ethers.Signer): Promise<void>;
|
|
11
|
+
isPricingModule(moduleAddress: string): Promise<boolean>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=PricingModules.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PricingModules.d.ts","sourceRoot":"","sources":["../../src/pricing-modules/PricingModules.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAA;AAClD,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAA;AAG5D,qBAAa,cAAc;IACvB,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAc;gBAE9B,MAAM,EAAE,eAAe,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;IAIjE,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK;IAI3B,kBAAkB,IAAI,OAAO,CAAC,mBAAmB,EAAE,CAAC;IAIpD,gBAAgB,CAAC,aAAa,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAI7E,mBAAmB,CAAC,aAAa,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAIhF,eAAe,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;CAGxE"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { IPricingShim } from './IPricingShim';
|
|
2
|
+
export class PricingModules {
|
|
3
|
+
pricingShim;
|
|
4
|
+
constructor(config, provider) {
|
|
5
|
+
this.pricingShim = new IPricingShim(config.addresses.spaceFactory, provider);
|
|
6
|
+
}
|
|
7
|
+
parseError(error) {
|
|
8
|
+
return this.pricingShim.parseError(error);
|
|
9
|
+
}
|
|
10
|
+
async listPricingModules() {
|
|
11
|
+
return this.pricingShim.read.listPricingModules();
|
|
12
|
+
}
|
|
13
|
+
async addPricingModule(moduleAddress, signer) {
|
|
14
|
+
await this.pricingShim.write(signer).addPricingModule(moduleAddress);
|
|
15
|
+
}
|
|
16
|
+
async removePricingModule(moduleAddress, signer) {
|
|
17
|
+
await this.pricingShim.write(signer).removePricingModule(moduleAddress);
|
|
18
|
+
}
|
|
19
|
+
async isPricingModule(moduleAddress) {
|
|
20
|
+
return this.pricingShim.read.isPricingModule(moduleAddress);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=PricingModules.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PricingModules.js","sourceRoot":"","sources":["../../src/pricing-modules/PricingModules.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAE7C,MAAM,OAAO,cAAc;IACN,WAAW,CAAc;IAE1C,YAAY,MAAuB,EAAE,QAAmC;QACpE,IAAI,CAAC,WAAW,GAAG,IAAI,YAAY,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,EAAE,QAAQ,CAAC,CAAA;IAChF,CAAC;IAEM,UAAU,CAAC,KAAc;QAC5B,OAAO,IAAI,CAAC,WAAW,CAAC,UAAU,CAAC,KAAK,CAAC,CAAA;IAC7C,CAAC;IAEM,KAAK,CAAC,kBAAkB;QAC3B,OAAO,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,kBAAkB,EAAE,CAAA;IACrD,CAAC;IAEM,KAAK,CAAC,gBAAgB,CAAC,aAAqB,EAAE,MAAqB;QACtE,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,gBAAgB,CAAC,aAAa,CAAC,CAAA;IACxE,CAAC;IAEM,KAAK,CAAC,mBAAmB,CAAC,aAAqB,EAAE,MAAqB;QACzE,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,mBAAmB,CAAC,aAAa,CAAC,CAAA;IAC3E,CAAC;IAEM,KAAK,CAAC,eAAe,CAAC,aAAqB;QAC9C,OAAO,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC,CAAA;IAC/D,CAAC;CACJ"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SpaceDapp } from '../space-dapp/SpaceDapp';
|
|
2
|
+
import { PricingModuleStruct } from '../types/ContractTypes';
|
|
3
|
+
/**
|
|
4
|
+
* @deprecated
|
|
5
|
+
* Use TIERED_PRICING_ORACLE_V2 or TIERED_PRICING_ORACLE_V3 instead
|
|
6
|
+
* Yes, the correct value for this constant is "TieredLogPricingOracleV2"
|
|
7
|
+
*/
|
|
8
|
+
export declare const TIERED_PRICING_ORACLE = "TieredLogPricingOracleV2";
|
|
9
|
+
export declare const TIERED_PRICING_ORACLE_V2 = "TieredLogPricingOracleV2";
|
|
10
|
+
export declare const TIERED_PRICING_ORACLE_V3 = "TieredLogPricingOracleV3";
|
|
11
|
+
export declare const FIXED_PRICING = "FixedPricing";
|
|
12
|
+
export declare const getDynamicPricingModule: (spaceDapp: SpaceDapp | undefined) => Promise<import("@towns-labs/generated/dev/typings/IPricingModules").IPricingModulesBase.PricingModuleStruct>;
|
|
13
|
+
export declare const getFixedPricingModule: (spaceDapp: SpaceDapp | undefined) => Promise<import("@towns-labs/generated/dev/typings/IPricingModules").IPricingModulesBase.PricingModuleStruct>;
|
|
14
|
+
export declare const findDynamicPricingModule: (pricingModules: PricingModuleStruct[]) => import("@towns-labs/generated/dev/typings/IPricingModules").IPricingModulesBase.PricingModuleStruct | undefined;
|
|
15
|
+
export declare const findFixedPricingModule: (pricingModules: PricingModuleStruct[]) => import("@towns-labs/generated/dev/typings/IPricingModules").IPricingModulesBase.PricingModuleStruct | undefined;
|
|
16
|
+
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../src/pricing-modules/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAA;AACnD,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAA;AAE5D;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,6BAA6B,CAAA;AAC/D,eAAO,MAAM,wBAAwB,6BAA6B,CAAA;AAClE,eAAO,MAAM,wBAAwB,6BAA6B,CAAA;AAClE,eAAO,MAAM,aAAa,iBAAiB,CAAA;AAE3C,eAAO,MAAM,uBAAuB,GAAU,WAAW,SAAS,GAAG,SAAS,iHAU7E,CAAA;AAED,eAAO,MAAM,qBAAqB,GAAU,WAAW,SAAS,GAAG,SAAS,iHAU3E,CAAA;AAED,eAAO,MAAM,wBAAwB,GAAI,gBAAgB,mBAAmB,EAAE,oHAED,CAAA;AAE7E,eAAO,MAAM,sBAAsB,GAAI,gBAAgB,mBAAmB,EAAE,oHACV,CAAA"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated
|
|
3
|
+
* Use TIERED_PRICING_ORACLE_V2 or TIERED_PRICING_ORACLE_V3 instead
|
|
4
|
+
* Yes, the correct value for this constant is "TieredLogPricingOracleV2"
|
|
5
|
+
*/
|
|
6
|
+
export const TIERED_PRICING_ORACLE = 'TieredLogPricingOracleV2';
|
|
7
|
+
export const TIERED_PRICING_ORACLE_V2 = 'TieredLogPricingOracleV2';
|
|
8
|
+
export const TIERED_PRICING_ORACLE_V3 = 'TieredLogPricingOracleV3';
|
|
9
|
+
export const FIXED_PRICING = 'FixedPricing';
|
|
10
|
+
export const getDynamicPricingModule = async (spaceDapp) => {
|
|
11
|
+
if (!spaceDapp) {
|
|
12
|
+
throw new Error('getDynamicPricingModule: No spaceDapp');
|
|
13
|
+
}
|
|
14
|
+
const pricingModules = await spaceDapp.listPricingModules();
|
|
15
|
+
const dynamicPricingModule = findDynamicPricingModule(pricingModules);
|
|
16
|
+
if (!dynamicPricingModule) {
|
|
17
|
+
throw new Error('getDynamicPricingModule: no dynamicPricingModule');
|
|
18
|
+
}
|
|
19
|
+
return dynamicPricingModule;
|
|
20
|
+
};
|
|
21
|
+
export const getFixedPricingModule = async (spaceDapp) => {
|
|
22
|
+
if (!spaceDapp) {
|
|
23
|
+
throw new Error('getFixedPricingModule: No spaceDapp');
|
|
24
|
+
}
|
|
25
|
+
const pricingModules = await spaceDapp.listPricingModules();
|
|
26
|
+
const fixedPricingModule = findFixedPricingModule(pricingModules);
|
|
27
|
+
if (!fixedPricingModule) {
|
|
28
|
+
throw new Error('getFixedPricingModule: no fixedPricingModule');
|
|
29
|
+
}
|
|
30
|
+
return fixedPricingModule;
|
|
31
|
+
};
|
|
32
|
+
export const findDynamicPricingModule = (pricingModules) => pricingModules.find((module) => module.name === TIERED_PRICING_ORACLE_V3) ||
|
|
33
|
+
pricingModules.find((module) => module.name === TIERED_PRICING_ORACLE_V2);
|
|
34
|
+
export const findFixedPricingModule = (pricingModules) => pricingModules.find((module) => module.name === FIXED_PRICING);
|
|
35
|
+
//# sourceMappingURL=helpers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../src/pricing-modules/helpers.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,0BAA0B,CAAA;AAC/D,MAAM,CAAC,MAAM,wBAAwB,GAAG,0BAA0B,CAAA;AAClE,MAAM,CAAC,MAAM,wBAAwB,GAAG,0BAA0B,CAAA;AAClE,MAAM,CAAC,MAAM,aAAa,GAAG,cAAc,CAAA;AAE3C,MAAM,CAAC,MAAM,uBAAuB,GAAG,KAAK,EAAE,SAAgC,EAAE,EAAE;IAC9E,IAAI,CAAC,SAAS,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CAAC,uCAAuC,CAAC,CAAA;IAC5D,CAAC;IACD,MAAM,cAAc,GAAG,MAAM,SAAS,CAAC,kBAAkB,EAAE,CAAA;IAC3D,MAAM,oBAAoB,GAAG,wBAAwB,CAAC,cAAc,CAAC,CAAA;IACrE,IAAI,CAAC,oBAAoB,EAAE,CAAC;QACxB,MAAM,IAAI,KAAK,CAAC,kDAAkD,CAAC,CAAA;IACvE,CAAC;IACD,OAAO,oBAAoB,CAAA;AAC/B,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,qBAAqB,GAAG,KAAK,EAAE,SAAgC,EAAE,EAAE;IAC5E,IAAI,CAAC,SAAS,EAAE,CAAC;QACb,MAAM,IAAI,KAAK,CAAC,qCAAqC,CAAC,CAAA;IAC1D,CAAC;IACD,MAAM,cAAc,GAAG,MAAM,SAAS,CAAC,kBAAkB,EAAE,CAAA;IAC3D,MAAM,kBAAkB,GAAG,sBAAsB,CAAC,cAAc,CAAC,CAAA;IACjE,IAAI,CAAC,kBAAkB,EAAE,CAAC;QACtB,MAAM,IAAI,KAAK,CAAC,8CAA8C,CAAC,CAAA;IACnE,CAAC;IACD,OAAO,kBAAkB,CAAA;AAC7B,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,cAAqC,EAAE,EAAE,CAC9E,cAAc,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,KAAK,wBAAwB,CAAC;IACzE,cAAc,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,KAAK,wBAAwB,CAAC,CAAA;AAE7E,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,cAAqC,EAAE,EAAE,CAC5E,cAAc,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,KAAK,aAAa,CAAC,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { Connect, ContractType } from './types/typechain';
|
|
3
|
+
type RetryOptions = {
|
|
4
|
+
maxAttempts?: number;
|
|
5
|
+
initialRetryDelay?: number;
|
|
6
|
+
maxRetryDelay?: number;
|
|
7
|
+
};
|
|
8
|
+
export declare function readRetryWrapper<T_CONTRACT extends ContractType<Connect<ethers.Contract>>>(contract: T_CONTRACT, retryOptions?: RetryOptions): T_CONTRACT;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=readContractRetryer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readContractRetryer.d.ts","sourceRoot":"","sources":["../src/readContractRetryer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAIzD,KAAK,YAAY,GAAG;IAChB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,aAAa,CAAC,EAAE,MAAM,CAAA;CACzB,CAAA;AAQD,wBAAgB,gBAAgB,CAAC,UAAU,SAAS,YAAY,CAAC,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,EACtF,QAAQ,EAAE,UAAU,EACpB,YAAY,GAAE,YAAiB,GAChC,UAAU,CAiFZ"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { dlogger } from '@towns-labs/utils';
|
|
2
|
+
const logger = dlogger('csb:readContractRetryer');
|
|
3
|
+
const DEFAULT_RETRY_OPTIONS = {
|
|
4
|
+
maxAttempts: 4,
|
|
5
|
+
initialRetryDelay: 1000,
|
|
6
|
+
maxRetryDelay: 8000,
|
|
7
|
+
};
|
|
8
|
+
export function readRetryWrapper(contract, retryOptions = {}) {
|
|
9
|
+
const opts = { ...DEFAULT_RETRY_OPTIONS, ...retryOptions };
|
|
10
|
+
const wrapper = Object.create(contract);
|
|
11
|
+
// ethers/typechain contracts have a set of functions.
|
|
12
|
+
// these functions are defined on the class itself, i.e. contract[myFunction]
|
|
13
|
+
// as well as in these properties, i.e. contract.callStatic.myFunction
|
|
14
|
+
// so, we're gonna replace all these with retry wrapper
|
|
15
|
+
const contractMethodProperties = [
|
|
16
|
+
'functions',
|
|
17
|
+
'callStatic',
|
|
18
|
+
'estimateGas',
|
|
19
|
+
'populateTransaction',
|
|
20
|
+
];
|
|
21
|
+
const functionNames = Object.keys(contract.functions);
|
|
22
|
+
const objectsWithContractMethods = ['root', ...contractMethodProperties];
|
|
23
|
+
for (const target of objectsWithContractMethods) {
|
|
24
|
+
const isRoot = target === 'root';
|
|
25
|
+
const source = isRoot ? wrapper : wrapper[target];
|
|
26
|
+
const destination = isRoot ? wrapper : Object.create(wrapper[target] || {});
|
|
27
|
+
for (const funcName of functionNames) {
|
|
28
|
+
const ogFunction = source?.[funcName];
|
|
29
|
+
if (typeof ogFunction === 'function') {
|
|
30
|
+
Object.defineProperty(destination, funcName, {
|
|
31
|
+
value: function (...args) {
|
|
32
|
+
return (async () => {
|
|
33
|
+
let attempt = 0;
|
|
34
|
+
// eslint-disable-next-line no-constant-condition
|
|
35
|
+
while (true) {
|
|
36
|
+
attempt++;
|
|
37
|
+
try {
|
|
38
|
+
const result = ogFunction.apply(this, args);
|
|
39
|
+
return await result;
|
|
40
|
+
}
|
|
41
|
+
catch (error) {
|
|
42
|
+
if (attempt >= opts.maxAttempts) {
|
|
43
|
+
logger.error(`Read contract call failed after ${attempt} attempts:`, error);
|
|
44
|
+
throw error;
|
|
45
|
+
}
|
|
46
|
+
const retryDelay = Math.min(opts.maxRetryDelay, opts.initialRetryDelay * Math.pow(2, attempt - 1));
|
|
47
|
+
logger.log(`Read contract call failed for ${funcName} (attempt ${attempt}/${opts.maxAttempts}), retrying in ${retryDelay}ms:`, error);
|
|
48
|
+
await new Promise((resolve) => setTimeout(resolve, retryDelay));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
})();
|
|
52
|
+
},
|
|
53
|
+
configurable: true,
|
|
54
|
+
writable: true,
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
if (!isRoot) {
|
|
59
|
+
Object.defineProperty(wrapper, target, {
|
|
60
|
+
value: destination,
|
|
61
|
+
configurable: true,
|
|
62
|
+
writable: true,
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
return wrapper;
|
|
67
|
+
}
|
|
68
|
+
//# sourceMappingURL=readContractRetryer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":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ACV,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE;gBACnC,KAAK,EAAE,WAAW;gBAClB,YAAY,EAAE,IAAI;gBAClB,QAAQ,EAAE,IAAI;aACjB,CAAC,CAAA;QACN,CAAC;IACL,CAAC;IAED,OAAO,OAAO,CAAA;AAClB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
3
|
+
import { NodeRegistry__factory } from '@towns-protocol/generated/dev/typings/factories/NodeRegistry__factory';
|
|
4
|
+
declare const connect: typeof NodeRegistry__factory.connect;
|
|
5
|
+
export declare class INodeRegistryShim extends BaseContractShim<typeof connect> {
|
|
6
|
+
constructor(address: string, provider: ethers.providers.Provider);
|
|
7
|
+
}
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=INodeRegistryShim.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"INodeRegistryShim.d.ts","sourceRoot":"","sources":["../../src/river-registry/INodeRegistryShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uEAAuE,CAAA;AAE7G,QAAA,MAAa,OAAO,sCAA0B,CAAA;AAE9C,qBAAa,iBAAkB,SAAQ,gBAAgB,CAAC,OAAO,OAAO,CAAC;gBACvD,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;CAGnE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
2
|
+
import { NodeRegistry__factory } from '@towns-protocol/generated/dev/typings/factories/NodeRegistry__factory';
|
|
3
|
+
const { abi, connect } = NodeRegistry__factory;
|
|
4
|
+
export class INodeRegistryShim extends BaseContractShim {
|
|
5
|
+
constructor(address, provider) {
|
|
6
|
+
super(address, provider, connect, abi);
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=INodeRegistryShim.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"INodeRegistryShim.js","sourceRoot":"","sources":["../../src/river-registry/INodeRegistryShim.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uEAAuE,CAAA;AAE7G,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,qBAAqB,CAAA;AAE9C,MAAM,OAAO,iBAAkB,SAAQ,gBAAgC;IACnE,YAAY,OAAe,EAAE,QAAmC;QAC5D,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAA;IAC1C,CAAC;CACJ"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { OperatorRegistry__factory } from '@towns-labs/generated/dev/typings/factories/OperatorRegistry__factory';
|
|
2
|
+
import { ethers } from 'ethers';
|
|
3
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
4
|
+
declare const connect: typeof OperatorRegistry__factory.connect;
|
|
5
|
+
export declare class IOperatorRegistryShim extends BaseContractShim<typeof connect> {
|
|
6
|
+
constructor(address: string, provider: ethers.providers.Provider);
|
|
7
|
+
}
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=IOperatorRegistryShim.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IOperatorRegistryShim.d.ts","sourceRoot":"","sources":["../../src/river-registry/IOperatorRegistryShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,uEAAuE,CAAA;AACjH,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAEtD,QAAA,MAAa,OAAO,0CAA8B,CAAA;AAElD,qBAAa,qBAAsB,SAAQ,gBAAgB,CAAC,OAAO,OAAO,CAAC;gBAC3D,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;CAGnE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { OperatorRegistry__factory } from '@towns-labs/generated/dev/typings/factories/OperatorRegistry__factory';
|
|
2
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
3
|
+
const { abi, connect } = OperatorRegistry__factory;
|
|
4
|
+
export class IOperatorRegistryShim extends BaseContractShim {
|
|
5
|
+
constructor(address, provider) {
|
|
6
|
+
super(address, provider, connect, abi);
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=IOperatorRegistryShim.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IOperatorRegistryShim.js","sourceRoot":"","sources":["../../src/river-registry/IOperatorRegistryShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,uEAAuE,CAAA;AAEjH,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAEtD,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,yBAAyB,CAAA;AAElD,MAAM,OAAO,qBAAsB,SAAQ,gBAAgC;IACvE,YAAY,OAAe,EAAE,QAAmC;QAC5D,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAA;IAC1C,CAAC;CACJ"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { StreamRegistry__factory } from '@towns-labs/generated/dev/typings/factories/StreamRegistry__factory';
|
|
2
|
+
import { ethers } from 'ethers';
|
|
3
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
4
|
+
declare const connect: typeof StreamRegistry__factory.connect;
|
|
5
|
+
export declare class IStreamRegistryShim extends BaseContractShim<typeof connect> {
|
|
6
|
+
constructor(address: string, provider: ethers.providers.Provider);
|
|
7
|
+
}
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=IStreamRegistryShim.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IStreamRegistryShim.d.ts","sourceRoot":"","sources":["../../src/river-registry/IStreamRegistryShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,qEAAqE,CAAA;AAC7G,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAEtD,QAAA,MAAa,OAAO,wCAA4B,CAAA;AAEhD,qBAAa,mBAAoB,SAAQ,gBAAgB,CAAC,OAAO,OAAO,CAAC;gBACzD,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;CAGnE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { StreamRegistry__factory } from '@towns-labs/generated/dev/typings/factories/StreamRegistry__factory';
|
|
2
|
+
import { BaseContractShim } from '../BaseContractShim';
|
|
3
|
+
const { abi, connect } = StreamRegistry__factory;
|
|
4
|
+
export class IStreamRegistryShim extends BaseContractShim {
|
|
5
|
+
constructor(address, provider) {
|
|
6
|
+
super(address, provider, connect, abi);
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=IStreamRegistryShim.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IStreamRegistryShim.js","sourceRoot":"","sources":["../../src/river-registry/IStreamRegistryShim.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,qEAAqE,CAAA;AAE7G,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAEtD,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,uBAAuB,CAAA;AAEhD,MAAM,OAAO,mBAAoB,SAAQ,gBAAgC;IACrE,YAAY,OAAe,EAAE,QAAmC;QAC5D,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAA;IAC1C,CAAC;CACJ"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ethers } from 'ethers';
|
|
2
|
+
import { RiverChainConfig } from '../utils/web3Env';
|
|
3
|
+
import { IStreamRegistryShim } from './IStreamRegistryShim';
|
|
4
|
+
import { IOperatorRegistryShim } from './IOperatorRegistryShim';
|
|
5
|
+
import { StreamStructOutput } from '@towns-labs/generated/dev/typings/IStreamRegistry';
|
|
6
|
+
export declare class RiverRegistry {
|
|
7
|
+
readonly config: RiverChainConfig;
|
|
8
|
+
readonly provider: ethers.providers.Provider;
|
|
9
|
+
readonly streamRegistry: IStreamRegistryShim;
|
|
10
|
+
readonly operatorRegistry: IOperatorRegistryShim;
|
|
11
|
+
constructor(config: RiverChainConfig, provider: ethers.providers.Provider);
|
|
12
|
+
getStreamCount(): Promise<ethers.BigNumber>;
|
|
13
|
+
getStream(streamAddress: Uint8Array): Promise<StreamStructOutput>;
|
|
14
|
+
streamExists(streamAddress: Uint8Array): Promise<boolean>;
|
|
15
|
+
private getStreamCountOnNode;
|
|
16
|
+
getStreamCountsOnNodes(nodeAddresses: string[]): Promise<ethers.BigNumber[]>;
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=RiverRegistry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RiverRegistry.d.ts","sourceRoot":"","sources":["../../src/river-registry/RiverRegistry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AAC/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mDAAmD,CAAA;AAEtF,qBAAa,aAAa;IACtB,SAAgB,MAAM,EAAE,gBAAgB,CAAA;IACxC,SAAgB,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAA;IACnD,SAAgB,cAAc,EAAE,mBAAmB,CAAA;IACnD,SAAgB,gBAAgB,EAAE,qBAAqB,CAAA;gBAE3C,MAAM,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,CAAC,SAAS,CAAC,QAAQ;IAOnE,cAAc,IAAI,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC;IAI3C,SAAS,CAAC,aAAa,EAAE,UAAU,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAIjE,YAAY,CAAC,aAAa,EAAE,UAAU,GAAG,OAAO,CAAC,OAAO,CAAC;YAajD,oBAAoB;IAIrB,sBAAsB,CAAC,aAAa,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,SAAS,EAAE,CAAC;CAK5F"}
|