@evergonlabs/tmi-protocol-api 0.8.1 → 0.9.0
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/app.d.ts +462 -67
- package/dist/app.d.ts.map +1 -1
- package/dist/client.d.ts +591 -180
- package/dist/client.d.ts.map +1 -1
- package/dist/common/middleware/indexer.d.ts +1 -1
- package/dist/common/middleware/indexer.d.ts.map +1 -1
- package/dist/factory.d.ts +1 -3
- package/dist/factory.d.ts.map +1 -1
- package/dist/fractions/fractions/approveWrapper.route.d.ts +3 -3
- package/dist/fractions/fractions/approveWrapper.route.d.ts.map +1 -1
- package/dist/fractions/fractions/index.d.ts +1 -1
- package/dist/fractions/fractions/index.d.ts.map +1 -1
- package/dist/fractions/index.d.ts +154 -6
- package/dist/fractions/index.d.ts.map +1 -1
- package/dist/fractions/markets/getDeployEvent.d.ts +1 -1
- package/dist/fractions/markets/getDeployEvent.d.ts.map +1 -1
- package/dist/fractions/markets/getMarket/getMarket.d.ts +22 -2
- package/dist/fractions/markets/getMarket/getMarket.d.ts.map +1 -1
- package/dist/fractions/markets/getMarket/index.d.ts +22 -2
- package/dist/fractions/markets/getMarket/index.d.ts.map +1 -1
- package/dist/fractions/markets/index.d.ts +43 -3
- package/dist/fractions/markets/index.d.ts.map +1 -1
- package/dist/fractions/markets/searchMarkets/index.d.ts +22 -2
- package/dist/fractions/markets/searchMarkets/index.d.ts.map +1 -1
- package/dist/fractions/markets/searchMarkets/searchMarkets.d.ts +22 -2
- package/dist/fractions/markets/searchMarkets/searchMarkets.d.ts.map +1 -1
- package/dist/fractions/platforms/deployMarket.routes.d.ts +4 -4
- package/dist/fractions/platforms/deployMarket.routes.d.ts.map +1 -1
- package/dist/fractions/platforms/index.d.ts +1 -1
- package/dist/fractions/platforms/index.d.ts.map +1 -1
- package/dist/fractions/platforms/initCompilot.routes.d.ts +1 -1
- package/dist/fractions/platforms/initCompilot.routes.d.ts.map +1 -1
- package/dist/fractions/platforms/initNid.route.d.ts +1 -1
- package/dist/fractions/platforms/initNid.route.d.ts.map +1 -1
- package/dist/fractions/roles/getRoles.d.ts +1 -1
- package/dist/fractions/roles/getRoles.d.ts.map +1 -1
- package/dist/fractions/roles/grantRole.route.d.ts +1 -1
- package/dist/fractions/roles/grantRole.route.d.ts.map +1 -1
- package/dist/fractions/roles/index.d.ts +1 -1
- package/dist/fractions/roles/index.d.ts.map +1 -1
- package/dist/fractions/sales/approveSale.route.d.ts +1 -1
- package/dist/fractions/sales/approveSale.route.d.ts.map +1 -1
- package/dist/fractions/sales/completeSale.route.d.ts +1 -1
- package/dist/fractions/sales/completeSale.route.d.ts.map +1 -1
- package/dist/fractions/sales/createFractions.route.d.ts +1 -1
- package/dist/fractions/sales/createFractions.route.d.ts.map +1 -1
- package/dist/fractions/sales/getFractionSaleStatistics.route.d.ts +1 -1
- package/dist/fractions/sales/getFractionSaleStatistics.route.d.ts.map +1 -1
- package/dist/fractions/sales/getVaultAddress.d.ts +1 -1
- package/dist/fractions/sales/getVaultAddress.d.ts.map +1 -1
- package/dist/fractions/sales/getWithdrawEvent.d.ts +1 -1
- package/dist/fractions/sales/getWithdrawEvent.d.ts.map +1 -1
- package/dist/fractions/sales/index.d.ts +112 -4
- package/dist/fractions/sales/index.d.ts.map +1 -1
- package/dist/fractions/sales/parseFractionsCreatedEvent.d.ts +1 -1
- package/dist/fractions/sales/parseFractionsCreatedEvent.d.ts.map +1 -1
- package/dist/fractions/sales/purchase.route.d.ts +1 -1
- package/dist/fractions/sales/purchase.route.d.ts.map +1 -1
- package/dist/fractions/sales/purchaseStatistics.route.d.ts +1 -1
- package/dist/fractions/sales/purchaseStatistics.route.d.ts.map +1 -1
- package/dist/fractions/sales/receiveFundsAfterNonFunded.route.d.ts +2 -2
- package/dist/fractions/sales/receiveFundsAfterNonFunded.route.d.ts.map +1 -1
- package/dist/fractions/sales/receiveNonPurchasedWrappedAssets.route.d.ts +1 -1
- package/dist/fractions/sales/receiveNonPurchasedWrappedAssets.route.d.ts.map +1 -1
- package/dist/fractions/sales/recoverFractions.d.ts +1 -1
- package/dist/fractions/sales/recoverFractions.d.ts.map +1 -1
- package/dist/fractions/sales/rejectFractions.d.ts +1 -1
- package/dist/fractions/sales/rejectFractions.d.ts.map +1 -1
- package/dist/fractions/sales/searchActivity.route.d.ts +1 -1
- package/dist/fractions/sales/searchActivity.route.d.ts.map +1 -1
- package/dist/fractions/sales/searchSales/searchSales.d.ts +67 -2
- package/dist/fractions/sales/searchSales/searchSales.d.ts.map +1 -1
- package/dist/fractions/sales/searchWithdrawal.route.d.ts +35 -2
- package/dist/fractions/sales/searchWithdrawal.route.d.ts.map +1 -1
- package/dist/fractions/sales/setFeeCapLimit.d.ts +1 -1
- package/dist/fractions/sales/setFeeCapLimit.d.ts.map +1 -1
- package/dist/fractions/sales/unlockWrappedAssets.route.d.ts +1 -1
- package/dist/fractions/sales/unlockWrappedAssets.route.d.ts.map +1 -1
- package/dist/fractions/sales/vesting/claimStatistics.route.d.ts +12 -2
- package/dist/fractions/sales/vesting/claimStatistics.route.d.ts.map +1 -1
- package/dist/fractions/sales/vesting/claimVestedTokens.route.d.ts +1 -1
- package/dist/fractions/sales/vesting/claimVestedTokens.route.d.ts.map +1 -1
- package/dist/fractions/sales/vesting/editCliff.route.d.ts +1 -1
- package/dist/fractions/sales/vesting/editCliff.route.d.ts.map +1 -1
- package/dist/fractions/sales/vesting/parseClaimVestedTokensEvent.d.ts +1 -1
- package/dist/fractions/sales/vesting/parseClaimVestedTokensEvent.d.ts.map +1 -1
- package/dist/fractions/sales/withdraw.route.d.ts +1 -1
- package/dist/fractions/sales/withdraw.route.d.ts.map +1 -1
- package/dist/fractions/sig/getAuthData.d.ts +1 -1
- package/dist/fractions/sig/getAuthData.d.ts.map +1 -1
- package/dist/fractions/sig/getNonce.route.d.ts +1 -1
- package/dist/fractions/sig/getNonce.route.d.ts.map +1 -1
- package/dist/fractions/sig/index.d.ts +1 -1
- package/dist/fractions/sig/index.d.ts.map +1 -1
- package/dist/fractions/statistics/index.d.ts +1 -1
- package/dist/fractions/statistics/index.d.ts.map +1 -1
- package/dist/fractions/statistics/networkStatistics.route.d.ts +4 -4
- package/dist/fractions/statistics/networkStatistics.route.d.ts.map +1 -1
- package/dist/general/estimateGas.d.ts +1 -1
- package/dist/general/estimateGas.d.ts.map +1 -1
- package/dist/general/getBalance.d.ts +1 -1
- package/dist/general/getBalance.d.ts.map +1 -1
- package/dist/general/getBalancesBatch.d.ts +1 -1
- package/dist/general/getBalancesBatch.d.ts.map +1 -1
- package/dist/general/index.d.ts +1 -1
- package/dist/general/index.d.ts.map +1 -1
- package/dist/general/searchBalances.d.ts +1 -1
- package/dist/general/searchBalances.d.ts.map +1 -1
- package/dist/issuance/common/exports.d.ts +1 -1
- package/dist/issuance/common/exports.d.ts.map +1 -1
- package/dist/issuance/common/exports.js +1 -1
- package/dist/issuance/common/factories.base.d.ts +167 -0
- package/dist/issuance/common/factories.base.d.ts.map +1 -0
- package/dist/issuance/common/factories.base.js +15 -0
- package/dist/issuance/common/factories.d.ts +1 -166
- package/dist/issuance/common/factories.d.ts.map +1 -1
- package/dist/issuance/common/factories.js +2 -15
- package/dist/issuance/erc20/approve.d.ts +1 -1
- package/dist/issuance/erc20/approve.d.ts.map +1 -1
- package/dist/issuance/erc20/burn.d.ts +1 -1
- package/dist/issuance/erc20/burn.d.ts.map +1 -1
- package/dist/issuance/erc20/default/deploy.d.ts +38 -0
- package/dist/issuance/erc20/default/deploy.d.ts.map +1 -0
- package/dist/issuance/erc20/default/deploy.js +54 -0
- package/dist/issuance/erc20/default/initialize.d.ts +38 -0
- package/dist/issuance/erc20/default/initialize.d.ts.map +1 -0
- package/dist/issuance/erc20/default/initialize.js +43 -0
- package/dist/issuance/erc20/default/parseDeployEvent.d.ts +23 -0
- package/dist/issuance/erc20/default/parseDeployEvent.d.ts.map +1 -0
- package/dist/issuance/erc20/default/parseDeployEvent.js +79 -0
- package/dist/issuance/erc20/gated/deploy.d.ts +40 -0
- package/dist/issuance/erc20/gated/deploy.d.ts.map +1 -0
- package/dist/issuance/erc20/gated/deploy.js +60 -0
- package/dist/issuance/erc20/gated/initialize.d.ts +40 -0
- package/dist/issuance/erc20/gated/initialize.d.ts.map +1 -0
- package/dist/issuance/erc20/gated/initialize.js +45 -0
- package/dist/issuance/erc20/gated/parseDeployEvent.d.ts +23 -0
- package/dist/issuance/erc20/gated/parseDeployEvent.d.ts.map +1 -0
- package/dist/issuance/erc20/gated/parseDeployEvent.js +79 -0
- package/dist/issuance/erc20/gatedSimple/deploy.d.ts +15 -0
- package/dist/issuance/erc20/gatedSimple/deploy.d.ts.map +1 -0
- package/dist/issuance/erc20/gatedSimple/deploy.js +28 -0
- package/dist/issuance/erc20/gatedSimple/getInitData.d.ts +32 -0
- package/dist/issuance/erc20/gatedSimple/getInitData.d.ts.map +1 -0
- package/dist/issuance/erc20/gatedSimple/getInitData.js +51 -0
- package/dist/issuance/erc20/gatedSimple/parseDeployEvent.d.ts +18 -0
- package/dist/issuance/erc20/gatedSimple/parseDeployEvent.d.ts.map +1 -0
- package/dist/issuance/erc20/gatedSimple/parseDeployEvent.js +63 -0
- package/dist/issuance/erc20/grantRole.d.ts +1 -1
- package/dist/issuance/erc20/grantRole.d.ts.map +1 -1
- package/dist/issuance/erc20/index.d.ts +126 -30
- package/dist/issuance/erc20/index.d.ts.map +1 -1
- package/dist/issuance/erc20/index.js +21 -7
- package/dist/issuance/erc20/mint.d.ts +1 -1
- package/dist/issuance/erc20/mint.d.ts.map +1 -1
- package/dist/issuance/erc20/recover.d.ts +1 -1
- package/dist/issuance/erc20/recover.d.ts.map +1 -1
- package/dist/issuance/erc20/renounceRole.d.ts +1 -1
- package/dist/issuance/erc20/renounceRole.d.ts.map +1 -1
- package/dist/issuance/erc20/revokeRole.d.ts +1 -1
- package/dist/issuance/erc20/revokeRole.d.ts.map +1 -1
- package/dist/issuance/erc20/transfer.d.ts +1 -1
- package/dist/issuance/erc20/transfer.d.ts.map +1 -1
- package/dist/issuance/erc20/transferFrom.d.ts +1 -1
- package/dist/issuance/erc20/transferFrom.d.ts.map +1 -1
- package/dist/issuance/erc721/approve.d.ts +1 -1
- package/dist/issuance/erc721/approve.d.ts.map +1 -1
- package/dist/issuance/erc721/burn.d.ts +1 -1
- package/dist/issuance/erc721/burn.d.ts.map +1 -1
- package/dist/issuance/erc721/default/deploy.d.ts +38 -0
- package/dist/issuance/erc721/default/deploy.d.ts.map +1 -0
- package/dist/issuance/erc721/default/deploy.js +53 -0
- package/dist/issuance/erc721/default/initialize.d.ts +38 -0
- package/dist/issuance/erc721/default/initialize.d.ts.map +1 -0
- package/dist/issuance/erc721/default/initialize.js +40 -0
- package/dist/issuance/erc721/default/parseDeployEvent.d.ts +23 -0
- package/dist/issuance/erc721/default/parseDeployEvent.d.ts.map +1 -0
- package/dist/issuance/erc721/default/parseDeployEvent.js +78 -0
- package/dist/issuance/erc721/gated/deploy.d.ts +40 -0
- package/dist/issuance/erc721/gated/deploy.d.ts.map +1 -0
- package/dist/issuance/erc721/gated/deploy.js +60 -0
- package/dist/issuance/erc721/gated/initialize.d.ts +40 -0
- package/dist/issuance/erc721/gated/initialize.d.ts.map +1 -0
- package/dist/issuance/erc721/gated/initialize.js +44 -0
- package/dist/issuance/erc721/gated/parseDeployEvent.d.ts +23 -0
- package/dist/issuance/erc721/gated/parseDeployEvent.d.ts.map +1 -0
- package/dist/issuance/erc721/gated/parseDeployEvent.js +78 -0
- package/dist/issuance/erc721/grantRole.d.ts +1 -1
- package/dist/issuance/erc721/grantRole.d.ts.map +1 -1
- package/dist/issuance/erc721/index.d.ts +78 -29
- package/dist/issuance/erc721/index.d.ts.map +1 -1
- package/dist/issuance/erc721/index.js +14 -7
- package/dist/issuance/erc721/mint.d.ts +1 -1
- package/dist/issuance/erc721/mint.d.ts.map +1 -1
- package/dist/issuance/erc721/recover.d.ts +1 -1
- package/dist/issuance/erc721/recover.d.ts.map +1 -1
- package/dist/issuance/erc721/renounceRole.d.ts +1 -1
- package/dist/issuance/erc721/renounceRole.d.ts.map +1 -1
- package/dist/issuance/erc721/revokeRole.d.ts +1 -1
- package/dist/issuance/erc721/revokeRole.d.ts.map +1 -1
- package/dist/issuance/erc721/setBaseURI.d.ts +1 -1
- package/dist/issuance/erc721/setBaseURI.d.ts.map +1 -1
- package/dist/issuance/erc721/setTokenURI.d.ts +1 -1
- package/dist/issuance/erc721/setTokenURI.d.ts.map +1 -1
- package/dist/issuance/erc721/transferFrom.d.ts +1 -1
- package/dist/issuance/erc721/transferFrom.d.ts.map +1 -1
- package/dist/issuance/index.d.ts +186 -41
- package/dist/issuance/index.d.ts.map +1 -1
- package/dist/issuance/proxy/deploy.d.ts +2 -2
- package/dist/issuance/proxy/deploy.d.ts.map +1 -1
- package/dist/issuance/proxy/index.d.ts +1 -1
- package/dist/issuance/proxy/index.d.ts.map +1 -1
- package/dist/issuance/proxy/upgrade.d.ts +1 -1
- package/dist/issuance/proxy/upgrade.d.ts.map +1 -1
- package/dist/next/fractions/index.d.ts +1 -1
- package/dist/next/fractions/index.d.ts.map +1 -1
- package/dist/next/fractions/lending/buyback/buyback.routes.d.ts +1 -1
- package/dist/next/fractions/lending/buyback/buyback.routes.d.ts.map +1 -1
- package/dist/next/fractions/lending/createLendingSale.d.ts +1 -1
- package/dist/next/fractions/lending/createLendingSale.d.ts.map +1 -1
- package/dist/next/fractions/lending/deployMarket/lending.routes.d.ts +1 -1
- package/dist/next/fractions/lending/deployMarket/lending.routes.d.ts.map +1 -1
- package/dist/next/fractions/lending/index.d.ts +1 -1
- package/dist/next/fractions/lending/index.d.ts.map +1 -1
- package/dist/next/fractions/lending/purchase/directPurchase.route.d.ts +1 -1
- package/dist/next/fractions/lending/purchase/directPurchase.route.d.ts.map +1 -1
- package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.routes.d.ts +1 -1
- package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.routes.d.ts.map +1 -1
- package/dist/next/fractions/platforms/deployNftFractionsMarket.routes.d.ts +1 -1
- package/dist/next/fractions/platforms/deployNftFractionsMarket.routes.d.ts.map +1 -1
- package/dist/next/fractions/platforms/index.d.ts +1 -1
- package/dist/next/fractions/platforms/index.d.ts.map +1 -1
- package/dist/next/fractions/sales/createNftFractions.routes.d.ts +1 -1
- package/dist/next/fractions/sales/createNftFractions.routes.d.ts.map +1 -1
- package/dist/next/fractions/sales/index.d.ts +1 -1
- package/dist/next/fractions/sales/index.d.ts.map +1 -1
- package/dist/staking/index.d.ts +76 -8
- package/dist/staking/index.d.ts.map +1 -1
- package/dist/staking/platforms/getPlatform/index.d.ts +1 -1
- package/dist/staking/platforms/getPlatform/index.d.ts.map +1 -1
- package/dist/staking/platforms/getPlatform/v0/getPlatform.d.ts +1 -1
- package/dist/staking/platforms/getPlatform/v0/getPlatform.d.ts.map +1 -1
- package/dist/staking/platforms/index.d.ts +1 -1
- package/dist/staking/platforms/index.d.ts.map +1 -1
- package/dist/staking/platforms/searchPlatforms/index.d.ts +1 -1
- package/dist/staking/platforms/searchPlatforms/index.d.ts.map +1 -1
- package/dist/staking/platforms/searchPlatforms/v0/searchPlatforms.d.ts +1 -1
- package/dist/staking/platforms/searchPlatforms/v0/searchPlatforms.d.ts.map +1 -1
- package/dist/staking/pools/getPool/index.d.ts +10 -2
- package/dist/staking/pools/getPool/index.d.ts.map +1 -1
- package/dist/staking/pools/getPool/v0/getPool.d.ts +11 -2
- package/dist/staking/pools/getPool/v0/getPool.d.ts.map +1 -1
- package/dist/staking/pools/index.d.ts +19 -3
- package/dist/staking/pools/index.d.ts.map +1 -1
- package/dist/staking/pools/searchPools/index.d.ts +10 -2
- package/dist/staking/pools/searchPools/index.d.ts.map +1 -1
- package/dist/staking/pools/searchPools/v0/searchPools.d.ts +11 -2
- package/dist/staking/pools/searchPools/v0/searchPools.d.ts.map +1 -1
- package/dist/staking/roles/getRoles/index.d.ts +1 -1
- package/dist/staking/roles/getRoles/index.d.ts.map +1 -1
- package/dist/staking/roles/getRoles/v0/getRoles.d.ts +1 -1
- package/dist/staking/roles/getRoles/v0/getRoles.d.ts.map +1 -1
- package/dist/staking/roles/grantRole/index.d.ts +1 -1
- package/dist/staking/roles/grantRole/index.d.ts.map +1 -1
- package/dist/staking/roles/grantRole/v0/grantRole.d.ts +1 -1
- package/dist/staking/roles/grantRole/v0/grantRole.d.ts.map +1 -1
- package/dist/staking/roles/index.d.ts +20 -3
- package/dist/staking/roles/index.d.ts.map +1 -1
- package/dist/staking/roles/searchRoleEvents/index.d.ts +11 -2
- package/dist/staking/roles/searchRoleEvents/index.d.ts.map +1 -1
- package/dist/staking/roles/searchRoleEvents/v0/searchRoleEvents.d.ts +11 -2
- package/dist/staking/roles/searchRoleEvents/v0/searchRoleEvents.d.ts.map +1 -1
- package/dist/staking/roles/searchRoles/index.d.ts +10 -2
- package/dist/staking/roles/searchRoles/index.d.ts.map +1 -1
- package/dist/staking/roles/searchRoles/v0/searchRoles.d.ts +11 -2
- package/dist/staking/roles/searchRoles/v0/searchRoles.d.ts.map +1 -1
- package/dist/staking/stakes/getStake/index.d.ts +15 -2
- package/dist/staking/stakes/getStake/index.d.ts.map +1 -1
- package/dist/staking/stakes/getStake/v0/getStake.d.ts +15 -2
- package/dist/staking/stakes/getStake/v0/getStake.d.ts.map +1 -1
- package/dist/staking/stakes/index.d.ts +39 -4
- package/dist/staking/stakes/index.d.ts.map +1 -1
- package/dist/staking/stakes/searchStakeEvents/index.d.ts +11 -2
- package/dist/staking/stakes/searchStakeEvents/index.d.ts.map +1 -1
- package/dist/staking/stakes/searchStakeEvents/v0/searchStakeEvents.d.ts +12 -2
- package/dist/staking/stakes/searchStakeEvents/v0/searchStakeEvents.d.ts.map +1 -1
- package/dist/staking/stakes/searchStakes/index.d.ts +15 -2
- package/dist/staking/stakes/searchStakes/index.d.ts.map +1 -1
- package/dist/staking/stakes/searchStakes/v0/searchStakes.d.ts +15 -2
- package/dist/staking/stakes/searchStakes/v0/searchStakes.d.ts.map +1 -1
- package/dist/stakingTemplates/index.d.ts +43 -7
- package/dist/stakingTemplates/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/getCreatePoolEvent.d.ts +6 -2
- package/dist/stakingTemplates/templates/common/getCreatePoolEvent.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/getPlatformDeployEvent.d.ts +1 -1
- package/dist/stakingTemplates/templates/common/getPlatformDeployEvent.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/getReward.d.ts +1 -1
- package/dist/stakingTemplates/templates/common/getReward.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/getStakeEvent.d.ts +10 -2
- package/dist/stakingTemplates/templates/common/getStakeEvent.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/partialUnstake.d.ts +1 -1
- package/dist/stakingTemplates/templates/common/partialUnstake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/common/unstake.d.ts +1 -1
- package/dist/stakingTemplates/templates/common/unstake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/reputation/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/createPlatform.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/createPlatform.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/createPool.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/createPool.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/reputation/v0/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/restake.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/restake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/stake.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputation/v0/stake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/reputationLock/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/createPlatform.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/createPlatform.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/createPool.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/createPool.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/reputationLock/v0/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/restake.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/restake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/stake.d.ts +1 -1
- package/dist/stakingTemplates/templates/reputationLock/v0/stake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/rwa/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/createPlatform.d.ts +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/createPlatform.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/createPool.d.ts +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/createPool.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/distributeRewards.d.ts +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/distributeRewards.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/index.d.ts +15 -3
- package/dist/stakingTemplates/templates/rwa/v0/index.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/restake.d.ts +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/restake.d.ts.map +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/stake.d.ts +1 -1
- package/dist/stakingTemplates/templates/rwa/v0/stake.d.ts.map +1 -1
- package/package.json +12 -12
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const InitializeErc721RequestSchema: z.ZodObject<{
|
|
3
|
+
tokenAddress: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
4
|
+
name: z.ZodString;
|
|
5
|
+
symbol: z.ZodString;
|
|
6
|
+
baseURI: z.ZodString;
|
|
7
|
+
defaultAdmin: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
8
|
+
minter: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
9
|
+
}, z.core.$strip>;
|
|
10
|
+
export declare const InitializeDefaultErc721: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
11
|
+
"/": {
|
|
12
|
+
$post: {
|
|
13
|
+
input: {
|
|
14
|
+
json: {
|
|
15
|
+
tokenAddress: string;
|
|
16
|
+
name: string;
|
|
17
|
+
symbol: string;
|
|
18
|
+
baseURI: string;
|
|
19
|
+
defaultAdmin: string;
|
|
20
|
+
minter: string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
output: {
|
|
24
|
+
data: `0x${string}`;
|
|
25
|
+
to: `0x${string}`;
|
|
26
|
+
details: {
|
|
27
|
+
functionName: string;
|
|
28
|
+
address: `0x${string}`;
|
|
29
|
+
abi: any[];
|
|
30
|
+
args: any[];
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
outputFormat: "json";
|
|
34
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
}, "/", "/">>;
|
|
38
|
+
//# sourceMappingURL=initialize.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"initialize.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/default/initialize.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,6BAA6B;;;;;;;iBAOxC,CAAC;AAkBH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;aAclC,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { z } from "zod";
|
|
4
|
+
import { abis } from "@evergonlabs/tmi-factories-sdk";
|
|
5
|
+
import { createController } from "../../../common/controller.js";
|
|
6
|
+
import { AddressSchema, toTransaction, TransactionSchema } from "../../../common/index.js";
|
|
7
|
+
export const InitializeErc721RequestSchema = z.object({
|
|
8
|
+
tokenAddress: AddressSchema,
|
|
9
|
+
name: z.string().nonempty().openapi({ description: "Name of the NFT collection" }),
|
|
10
|
+
symbol: z.string().nonempty().openapi({ description: "Symbol of the NFT collection" }),
|
|
11
|
+
baseURI: z.string().openapi({ description: "Base URI for token metadata" }),
|
|
12
|
+
defaultAdmin: AddressSchema.openapi({ description: "Address to receive DEFAULT_ADMIN_ROLE" }),
|
|
13
|
+
minter: AddressSchema.openapi({ description: "Address to receive MINTER_ROLE" }),
|
|
14
|
+
});
|
|
15
|
+
const initializeRoute = describeRoute({
|
|
16
|
+
summary: "Initialize ERC721",
|
|
17
|
+
description: "Returns transaction data for initializing an ERC721 token proxy contract",
|
|
18
|
+
tags: ["Issuance"],
|
|
19
|
+
responses: {
|
|
20
|
+
200: {
|
|
21
|
+
description: "Returns transaction data for initializing an ERC721 token",
|
|
22
|
+
content: {
|
|
23
|
+
"application/json": {
|
|
24
|
+
schema: resolver(TransactionSchema),
|
|
25
|
+
},
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
});
|
|
30
|
+
export const InitializeDefaultErc721 = createController({
|
|
31
|
+
build: (factory) => factory.createApp().post("/", initializeRoute, validator("json", InitializeErc721RequestSchema), async (c) => {
|
|
32
|
+
const { tokenAddress, name, symbol, baseURI, defaultAdmin, minter } = c.req.valid("json");
|
|
33
|
+
return c.json(toTransaction({
|
|
34
|
+
address: tokenAddress,
|
|
35
|
+
abi: abis.erc721PausableRecoverableUpgradeableAbi,
|
|
36
|
+
functionName: "initialize",
|
|
37
|
+
args: [name, symbol, baseURI, defaultAdmin, minter],
|
|
38
|
+
}));
|
|
39
|
+
}),
|
|
40
|
+
});
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const ParseDefaultErc721DeployEvent: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
2
|
+
"/": {
|
|
3
|
+
$get: {
|
|
4
|
+
input: {
|
|
5
|
+
query: {
|
|
6
|
+
chainId: string | string[];
|
|
7
|
+
hash: string | string[];
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
output: {
|
|
11
|
+
proxy: `0x${string}`;
|
|
12
|
+
admin: `0x${string}`;
|
|
13
|
+
minter: `0x${string}`;
|
|
14
|
+
name: string;
|
|
15
|
+
symbol: string;
|
|
16
|
+
baseURI: string;
|
|
17
|
+
};
|
|
18
|
+
outputFormat: "json";
|
|
19
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
}, "/", "/">>;
|
|
23
|
+
//# sourceMappingURL=parseDeployEvent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parseDeployEvent.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/default/parseDeployEvent.ts"],"names":[],"mappings":"AA2BA,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;aAoDxC,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { parseEventLogs } from "viem";
|
|
4
|
+
import { waitForTransactionReceipt } from "viem/actions";
|
|
5
|
+
import { z } from "zod";
|
|
6
|
+
import { abis } from "@evergonlabs/tmi-factories-sdk";
|
|
7
|
+
import { getPublicClient } from "../../../common/blockchain.js";
|
|
8
|
+
import { createController } from "../../../common/controller.js";
|
|
9
|
+
import { HttpError } from "../../../common/http-error.js";
|
|
10
|
+
import { AddressSchema, HashSchema } from "../../../common/index.js";
|
|
11
|
+
import { FactoryChainIdQuery } from "../../common/factories.js";
|
|
12
|
+
const QuerySchema = z.object({
|
|
13
|
+
chainId: FactoryChainIdQuery.openapi({
|
|
14
|
+
param: {
|
|
15
|
+
name: "chainId",
|
|
16
|
+
in: "query",
|
|
17
|
+
},
|
|
18
|
+
}),
|
|
19
|
+
hash: HashSchema.openapi({
|
|
20
|
+
param: {
|
|
21
|
+
name: "hash",
|
|
22
|
+
in: "query",
|
|
23
|
+
},
|
|
24
|
+
}),
|
|
25
|
+
});
|
|
26
|
+
export const ParseDefaultErc721DeployEvent = createController({
|
|
27
|
+
build: (factory) => factory.createApp().get("/", describeRoute({
|
|
28
|
+
summary: "Get ERC721 TokenProxyConfigured Event",
|
|
29
|
+
description: `Gets the transaction by hash and parses emitted logs.\n\nProvided transaction must be a transaction emitted by the ERC721 factory \`deployAndInitializeProxy\` action`,
|
|
30
|
+
tags: ["Issuance"],
|
|
31
|
+
responses: {
|
|
32
|
+
200: {
|
|
33
|
+
description: "Returns parsed event log",
|
|
34
|
+
content: {
|
|
35
|
+
"application/json": {
|
|
36
|
+
schema: resolver(z.object({
|
|
37
|
+
proxy: AddressSchema,
|
|
38
|
+
admin: AddressSchema,
|
|
39
|
+
minter: AddressSchema,
|
|
40
|
+
name: z.string(),
|
|
41
|
+
symbol: z.string(),
|
|
42
|
+
baseURI: z.string(),
|
|
43
|
+
})),
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
}), validator("query", QuerySchema), async (c) => {
|
|
49
|
+
const params = c.req.valid("query");
|
|
50
|
+
const receipt = await waitForTransactionReceipt(getPublicClient(params.chainId, c.env.config), {
|
|
51
|
+
hash: params.hash,
|
|
52
|
+
});
|
|
53
|
+
const [event] = parseEventLogs({
|
|
54
|
+
abi: abis.erc721PausableRecoverableFactoryAbi,
|
|
55
|
+
eventName: "TokenProxyConfigured",
|
|
56
|
+
logs: receipt.logs,
|
|
57
|
+
});
|
|
58
|
+
if (!event) {
|
|
59
|
+
throw new UnableParseDefaultErc721DeployEvent();
|
|
60
|
+
}
|
|
61
|
+
return c.json({
|
|
62
|
+
proxy: event.args.proxy,
|
|
63
|
+
admin: event.args.admin,
|
|
64
|
+
minter: event.args.minter,
|
|
65
|
+
name: event.args.name,
|
|
66
|
+
symbol: event.args.symbol,
|
|
67
|
+
baseURI: event.args.baseURI,
|
|
68
|
+
});
|
|
69
|
+
}),
|
|
70
|
+
});
|
|
71
|
+
class UnableParseDefaultErc721DeployEvent extends HttpError {
|
|
72
|
+
constructor() {
|
|
73
|
+
super(500, {
|
|
74
|
+
message: `Can't parse TokenProxyConfigured event. Make sure you're passing a transaction generated by the ERC721 factory \`deployAndInitializeProxy\` action`,
|
|
75
|
+
name: "UnableParseDefaultErc721DeployEvent",
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const DeployGatedErc721RequestSchema: z.ZodObject<{
|
|
3
|
+
chainId: z.ZodUnion<[z.ZodLiteral<11155111 | 72080>, z.ZodLiteral<11155111 | 72080>, ...z.ZodLiteral<11155111 | 72080>[]]>;
|
|
4
|
+
tokenName: z.ZodString;
|
|
5
|
+
tokenSymbol: z.ZodString;
|
|
6
|
+
baseURI: z.ZodString;
|
|
7
|
+
defaultTokenAdmin: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
8
|
+
minter: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
9
|
+
gatingSigner: z.ZodOptional<z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>>;
|
|
10
|
+
}, z.core.$strip>;
|
|
11
|
+
export declare const CreateGatedErc721Token: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
12
|
+
"/": {
|
|
13
|
+
$post: {
|
|
14
|
+
input: {
|
|
15
|
+
json: {
|
|
16
|
+
chainId: 11155111 | 72080;
|
|
17
|
+
tokenName: string;
|
|
18
|
+
tokenSymbol: string;
|
|
19
|
+
baseURI: string;
|
|
20
|
+
defaultTokenAdmin: string;
|
|
21
|
+
minter: string;
|
|
22
|
+
gatingSigner?: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
output: {
|
|
26
|
+
data: `0x${string}`;
|
|
27
|
+
to: `0x${string}`;
|
|
28
|
+
details: {
|
|
29
|
+
functionName: string;
|
|
30
|
+
address: `0x${string}`;
|
|
31
|
+
abi: any[];
|
|
32
|
+
args: any[];
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
outputFormat: "json";
|
|
36
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
}, "/", "/">>;
|
|
40
|
+
//# sourceMappingURL=deploy.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/gated/deploy.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,8BAA8B;;;;;;;;iBAUzC,CAAC;AA8BH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;aAiBjC,CAAC"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { z } from "zod";
|
|
4
|
+
import { abis } from "@evergonlabs/tmi-factories-sdk";
|
|
5
|
+
import { createController } from "../../../common/controller.js";
|
|
6
|
+
import { AddressSchema, toTransaction, TransactionSchema } from "../../../common/index.js";
|
|
7
|
+
import { DEFAULT_COMPILOT_SIGNER } from "../../../common/models/compilot.js";
|
|
8
|
+
import { FactoryChainId, getFactories } from "../../common/factories.js";
|
|
9
|
+
export const DeployGatedErc721RequestSchema = z.object({
|
|
10
|
+
chainId: FactoryChainId.Schema,
|
|
11
|
+
tokenName: z.string().nonempty().openapi({ description: "Name of the NFT collection" }),
|
|
12
|
+
tokenSymbol: z.string().nonempty().openapi({ description: "Symbol of the NFT collection" }),
|
|
13
|
+
baseURI: z.string().openapi({ description: "Base URI for token metadata" }),
|
|
14
|
+
defaultTokenAdmin: AddressSchema.openapi({ description: "Address to receive DEFAULT_ADMIN_ROLE" }),
|
|
15
|
+
minter: AddressSchema.openapi({ description: "Address to receive MINTER_ROLE" }),
|
|
16
|
+
gatingSigner: AddressSchema.optional().openapi({
|
|
17
|
+
description: "Address of the gating signer for whitelist verification. Defaults to the ComPilot signer.",
|
|
18
|
+
}),
|
|
19
|
+
});
|
|
20
|
+
const deployGatedErc721Route = describeRoute({
|
|
21
|
+
summary: "Deploy Gated ERC721 via Factory",
|
|
22
|
+
description: `This contract has not been audited.
|
|
23
|
+
|
|
24
|
+
Returns transaction data for deploying a new gated ERC721 token via the factory contract.
|
|
25
|
+
|
|
26
|
+
Calls deployAndInitializeProxy on the ERC721GatedPausableRecoverableFactory to atomically deploy and initialize a new token proxy with whitelist gating.
|
|
27
|
+
|
|
28
|
+
The deployed token supports:
|
|
29
|
+
- mint(to, tokenId) - Mint token (MINTER_ROLE gated)
|
|
30
|
+
- burn(tokenId) - Burn token (owner, approved, or MINTER_ROLE)
|
|
31
|
+
- setBaseURI(uri) - Set base URI (URI_SETTER_ROLE gated)
|
|
32
|
+
- setTokenURI(tokenId, uri) - Set token-specific URI (URI_SETTER_ROLE gated)
|
|
33
|
+
- setContractURI(uri) - Set contract metadata URI (URI_SETTER_ROLE gated)
|
|
34
|
+
- Whitelist gating via gatingSigner for transfer verification`,
|
|
35
|
+
tags: ["Issuance"],
|
|
36
|
+
responses: {
|
|
37
|
+
200: {
|
|
38
|
+
description: "Returns transaction data for deploying a gated ERC721 token via factory",
|
|
39
|
+
content: {
|
|
40
|
+
"application/json": {
|
|
41
|
+
schema: resolver(TransactionSchema),
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
export const CreateGatedErc721Token = createController({
|
|
48
|
+
build: (factory) => factory
|
|
49
|
+
.createApp()
|
|
50
|
+
.post("/", deployGatedErc721Route, validator("json", DeployGatedErc721RequestSchema), async (c) => {
|
|
51
|
+
const { chainId, tokenName, tokenSymbol, baseURI, defaultTokenAdmin, minter, gatingSigner } = c.req.valid("json");
|
|
52
|
+
const factory = getFactories(chainId);
|
|
53
|
+
return c.json(toTransaction({
|
|
54
|
+
address: factory.ERC721GatedPausableRecoverableFactory,
|
|
55
|
+
abi: abis.erc721GatedPausableRecoverableFactoryAbi,
|
|
56
|
+
functionName: "deployAndInitializeProxy",
|
|
57
|
+
args: [tokenName, tokenSymbol, baseURI, defaultTokenAdmin, minter, gatingSigner ?? DEFAULT_COMPILOT_SIGNER],
|
|
58
|
+
}));
|
|
59
|
+
}),
|
|
60
|
+
});
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const InitializeGatedErc721RequestSchema: z.ZodObject<{
|
|
3
|
+
tokenAddress: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
4
|
+
name: z.ZodString;
|
|
5
|
+
symbol: z.ZodString;
|
|
6
|
+
baseURI: z.ZodString;
|
|
7
|
+
defaultAdmin: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
8
|
+
minter: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
9
|
+
gatingSigner: z.ZodOptional<z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>>;
|
|
10
|
+
}, z.core.$strip>;
|
|
11
|
+
export declare const InitializeGatedErc721: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
12
|
+
"/": {
|
|
13
|
+
$post: {
|
|
14
|
+
input: {
|
|
15
|
+
json: {
|
|
16
|
+
tokenAddress: string;
|
|
17
|
+
name: string;
|
|
18
|
+
symbol: string;
|
|
19
|
+
baseURI: string;
|
|
20
|
+
defaultAdmin: string;
|
|
21
|
+
minter: string;
|
|
22
|
+
gatingSigner?: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
output: {
|
|
26
|
+
data: `0x${string}`;
|
|
27
|
+
to: `0x${string}`;
|
|
28
|
+
details: {
|
|
29
|
+
functionName: string;
|
|
30
|
+
address: `0x${string}`;
|
|
31
|
+
abi: any[];
|
|
32
|
+
args: any[];
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
outputFormat: "json";
|
|
36
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
}, "/", "/">>;
|
|
40
|
+
//# sourceMappingURL=initialize.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"initialize.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/gated/initialize.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,kCAAkC;;;;;;;;iBAU7C,CAAC;AAkBH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;aAchC,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { z } from "zod";
|
|
4
|
+
import { abis } from "@evergonlabs/tmi-factories-sdk";
|
|
5
|
+
import { createController } from "../../../common/controller.js";
|
|
6
|
+
import { AddressSchema, toTransaction, TransactionSchema } from "../../../common/index.js";
|
|
7
|
+
import { DEFAULT_COMPILOT_SIGNER } from "../../../common/models/compilot.js";
|
|
8
|
+
export const InitializeGatedErc721RequestSchema = z.object({
|
|
9
|
+
tokenAddress: AddressSchema,
|
|
10
|
+
name: z.string().nonempty().openapi({ description: "Name of the NFT collection" }),
|
|
11
|
+
symbol: z.string().nonempty().openapi({ description: "Symbol of the NFT collection" }),
|
|
12
|
+
baseURI: z.string().openapi({ description: "Base URI for token metadata" }),
|
|
13
|
+
defaultAdmin: AddressSchema.openapi({ description: "Address to receive DEFAULT_ADMIN_ROLE" }),
|
|
14
|
+
minter: AddressSchema.openapi({ description: "Address to receive MINTER_ROLE" }),
|
|
15
|
+
gatingSigner: AddressSchema.optional().openapi({
|
|
16
|
+
description: "Address of the gating signer for whitelist verification. Defaults to the ComPilot signer.",
|
|
17
|
+
}),
|
|
18
|
+
});
|
|
19
|
+
const initializeRoute = describeRoute({
|
|
20
|
+
summary: "Initialize Gated ERC721",
|
|
21
|
+
description: "Returns transaction data for initializing a gated ERC721 token proxy contract",
|
|
22
|
+
tags: ["Issuance"],
|
|
23
|
+
responses: {
|
|
24
|
+
200: {
|
|
25
|
+
description: "Returns transaction data for initializing a gated ERC721 token",
|
|
26
|
+
content: {
|
|
27
|
+
"application/json": {
|
|
28
|
+
schema: resolver(TransactionSchema),
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
});
|
|
34
|
+
export const InitializeGatedErc721 = createController({
|
|
35
|
+
build: (factory) => factory.createApp().post("/", initializeRoute, validator("json", InitializeGatedErc721RequestSchema), async (c) => {
|
|
36
|
+
const { tokenAddress, name, symbol, baseURI, defaultAdmin, minter, gatingSigner } = c.req.valid("json");
|
|
37
|
+
return c.json(toTransaction({
|
|
38
|
+
address: tokenAddress,
|
|
39
|
+
abi: abis.erc721WhitelistGatedPausableRecoverableUpgradeableAbi,
|
|
40
|
+
functionName: "initialize",
|
|
41
|
+
args: [name, symbol, baseURI, defaultAdmin, minter, gatingSigner ?? DEFAULT_COMPILOT_SIGNER],
|
|
42
|
+
}));
|
|
43
|
+
}),
|
|
44
|
+
});
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const ParseGatedErc721DeployEvent: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
2
|
+
"/": {
|
|
3
|
+
$get: {
|
|
4
|
+
input: {
|
|
5
|
+
query: {
|
|
6
|
+
chainId: string | string[];
|
|
7
|
+
hash: string | string[];
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
output: {
|
|
11
|
+
proxy: `0x${string}`;
|
|
12
|
+
admin: `0x${string}`;
|
|
13
|
+
minter: `0x${string}`;
|
|
14
|
+
name: string;
|
|
15
|
+
symbol: string;
|
|
16
|
+
baseURI: string;
|
|
17
|
+
};
|
|
18
|
+
outputFormat: "json";
|
|
19
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
}, "/", "/">>;
|
|
23
|
+
//# sourceMappingURL=parseDeployEvent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parseDeployEvent.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/gated/parseDeployEvent.ts"],"names":[],"mappings":"AA2BA,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;aAoDtC,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { parseEventLogs } from "viem";
|
|
4
|
+
import { waitForTransactionReceipt } from "viem/actions";
|
|
5
|
+
import { z } from "zod";
|
|
6
|
+
import { abis } from "@evergonlabs/tmi-factories-sdk";
|
|
7
|
+
import { getPublicClient } from "../../../common/blockchain.js";
|
|
8
|
+
import { createController } from "../../../common/controller.js";
|
|
9
|
+
import { HttpError } from "../../../common/http-error.js";
|
|
10
|
+
import { AddressSchema, HashSchema } from "../../../common/index.js";
|
|
11
|
+
import { FactoryChainIdQuery } from "../../common/factories.js";
|
|
12
|
+
const QuerySchema = z.object({
|
|
13
|
+
chainId: FactoryChainIdQuery.openapi({
|
|
14
|
+
param: {
|
|
15
|
+
name: "chainId",
|
|
16
|
+
in: "query",
|
|
17
|
+
},
|
|
18
|
+
}),
|
|
19
|
+
hash: HashSchema.openapi({
|
|
20
|
+
param: {
|
|
21
|
+
name: "hash",
|
|
22
|
+
in: "query",
|
|
23
|
+
},
|
|
24
|
+
}),
|
|
25
|
+
});
|
|
26
|
+
export const ParseGatedErc721DeployEvent = createController({
|
|
27
|
+
build: (factory) => factory.createApp().get("/", describeRoute({
|
|
28
|
+
summary: "Get Gated ERC721 TokenProxyConfigured Event",
|
|
29
|
+
description: `Gets the transaction by hash and parses emitted logs.\n\nProvided transaction must be a transaction emitted by the Gated ERC721 factory \`deployAndInitializeProxy\` action`,
|
|
30
|
+
tags: ["Issuance"],
|
|
31
|
+
responses: {
|
|
32
|
+
200: {
|
|
33
|
+
description: "Returns parsed event log",
|
|
34
|
+
content: {
|
|
35
|
+
"application/json": {
|
|
36
|
+
schema: resolver(z.object({
|
|
37
|
+
proxy: AddressSchema,
|
|
38
|
+
admin: AddressSchema,
|
|
39
|
+
minter: AddressSchema,
|
|
40
|
+
name: z.string(),
|
|
41
|
+
symbol: z.string(),
|
|
42
|
+
baseURI: z.string(),
|
|
43
|
+
})),
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
}), validator("query", QuerySchema), async (c) => {
|
|
49
|
+
const params = c.req.valid("query");
|
|
50
|
+
const receipt = await waitForTransactionReceipt(getPublicClient(params.chainId, c.env.config), {
|
|
51
|
+
hash: params.hash,
|
|
52
|
+
});
|
|
53
|
+
const [event] = parseEventLogs({
|
|
54
|
+
abi: abis.erc721GatedPausableRecoverableFactoryAbi,
|
|
55
|
+
eventName: "TokenProxyConfigured",
|
|
56
|
+
logs: receipt.logs,
|
|
57
|
+
});
|
|
58
|
+
if (!event) {
|
|
59
|
+
throw new UnableParseGatedErc721DeployEvent();
|
|
60
|
+
}
|
|
61
|
+
return c.json({
|
|
62
|
+
proxy: event.args.proxy,
|
|
63
|
+
admin: event.args.admin,
|
|
64
|
+
minter: event.args.minter,
|
|
65
|
+
name: event.args.name,
|
|
66
|
+
symbol: event.args.symbol,
|
|
67
|
+
baseURI: event.args.baseURI,
|
|
68
|
+
});
|
|
69
|
+
}),
|
|
70
|
+
});
|
|
71
|
+
class UnableParseGatedErc721DeployEvent extends HttpError {
|
|
72
|
+
constructor() {
|
|
73
|
+
super(500, {
|
|
74
|
+
message: `Can't parse TokenProxyConfigured event. Make sure you're passing a transaction generated by the Gated ERC721 factory \`deployAndInitializeProxy\` action`,
|
|
75
|
+
name: "UnableParseGatedErc721DeployEvent",
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grantRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/grantRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAgC,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAE3G,eAAO,MAAM,4BAA4B;;;;iBAOvC,CAAC;AAkBH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"grantRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/grantRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAgC,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAE3G,eAAO,MAAM,4BAA4B;;;;iBAOvC,CAAC;AAkBH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;aAc1B,CAAC"}
|
|
@@ -26,6 +26,54 @@ export declare const Erc721Controller: import("../../common/controller.js").ICon
|
|
|
26
26
|
};
|
|
27
27
|
};
|
|
28
28
|
}, "/deploy"> | import("hono/types").MergeSchemaPath<{
|
|
29
|
+
"/": {
|
|
30
|
+
$post: {
|
|
31
|
+
input: {
|
|
32
|
+
json: {
|
|
33
|
+
tokenAddress: string;
|
|
34
|
+
name: string;
|
|
35
|
+
symbol: string;
|
|
36
|
+
baseURI: string;
|
|
37
|
+
defaultAdmin: string;
|
|
38
|
+
minter: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
output: {
|
|
42
|
+
data: `0x${string}`;
|
|
43
|
+
to: `0x${string}`;
|
|
44
|
+
details: {
|
|
45
|
+
functionName: string;
|
|
46
|
+
address: `0x${string}`;
|
|
47
|
+
abi: any[];
|
|
48
|
+
args: any[];
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
outputFormat: "json";
|
|
52
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
}, "/initialize"> | import("hono/types").MergeSchemaPath<{
|
|
56
|
+
"/": {
|
|
57
|
+
$get: {
|
|
58
|
+
input: {
|
|
59
|
+
query: {
|
|
60
|
+
chainId: string | string[];
|
|
61
|
+
hash: string | string[];
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
output: {
|
|
65
|
+
proxy: `0x${string}`;
|
|
66
|
+
admin: `0x${string}`;
|
|
67
|
+
minter: `0x${string}`;
|
|
68
|
+
name: string;
|
|
69
|
+
symbol: string;
|
|
70
|
+
baseURI: string;
|
|
71
|
+
};
|
|
72
|
+
outputFormat: "json";
|
|
73
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
}, "/getDeployEvent"> | import("hono/types").MergeSchemaPath<{
|
|
29
77
|
"/": {
|
|
30
78
|
$post: {
|
|
31
79
|
input: {
|
|
@@ -54,6 +102,34 @@ export declare const Erc721Controller: import("../../common/controller.js").ICon
|
|
|
54
102
|
};
|
|
55
103
|
};
|
|
56
104
|
}, "/deployGated"> | import("hono/types").MergeSchemaPath<{
|
|
105
|
+
"/": {
|
|
106
|
+
$post: {
|
|
107
|
+
input: {
|
|
108
|
+
json: {
|
|
109
|
+
tokenAddress: string;
|
|
110
|
+
name: string;
|
|
111
|
+
symbol: string;
|
|
112
|
+
baseURI: string;
|
|
113
|
+
defaultAdmin: string;
|
|
114
|
+
minter: string;
|
|
115
|
+
gatingSigner?: string | undefined;
|
|
116
|
+
};
|
|
117
|
+
};
|
|
118
|
+
output: {
|
|
119
|
+
data: `0x${string}`;
|
|
120
|
+
to: `0x${string}`;
|
|
121
|
+
details: {
|
|
122
|
+
functionName: string;
|
|
123
|
+
address: `0x${string}`;
|
|
124
|
+
abi: any[];
|
|
125
|
+
args: any[];
|
|
126
|
+
};
|
|
127
|
+
};
|
|
128
|
+
outputFormat: "json";
|
|
129
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
130
|
+
};
|
|
131
|
+
};
|
|
132
|
+
}, "/initializeGated"> | import("hono/types").MergeSchemaPath<{
|
|
57
133
|
"/": {
|
|
58
134
|
$get: {
|
|
59
135
|
input: {
|
|
@@ -74,7 +150,7 @@ export declare const Erc721Controller: import("../../common/controller.js").ICon
|
|
|
74
150
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
75
151
|
};
|
|
76
152
|
};
|
|
77
|
-
}, "/
|
|
153
|
+
}, "/getDeployEventGated"> | import("hono/types").MergeSchemaPath<{
|
|
78
154
|
"/": {
|
|
79
155
|
$post: {
|
|
80
156
|
input: {
|
|
@@ -314,32 +390,5 @@ export declare const Erc721Controller: import("../../common/controller.js").ICon
|
|
|
314
390
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
315
391
|
};
|
|
316
392
|
};
|
|
317
|
-
}, "/setTokenURI"
|
|
318
|
-
"/": {
|
|
319
|
-
$post: {
|
|
320
|
-
input: {
|
|
321
|
-
json: {
|
|
322
|
-
tokenAddress: string;
|
|
323
|
-
name: string;
|
|
324
|
-
symbol: string;
|
|
325
|
-
baseURI: string;
|
|
326
|
-
defaultAdmin: string;
|
|
327
|
-
minter: string;
|
|
328
|
-
};
|
|
329
|
-
};
|
|
330
|
-
output: {
|
|
331
|
-
data: `0x${string}`;
|
|
332
|
-
to: `0x${string}`;
|
|
333
|
-
details: {
|
|
334
|
-
functionName: string;
|
|
335
|
-
address: `0x${string}`;
|
|
336
|
-
abi: any[];
|
|
337
|
-
args: any[];
|
|
338
|
-
};
|
|
339
|
-
};
|
|
340
|
-
outputFormat: "json";
|
|
341
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
342
|
-
};
|
|
343
|
-
};
|
|
344
|
-
}, "/initialize">, "/">>;
|
|
393
|
+
}, "/setTokenURI">, "/", "/">>;
|
|
345
394
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/index.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8BAuB3B,CAAC"}
|