@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,32 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const Erc20InitDataResponse: z.ZodObject<{
|
|
3
|
+
data: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
4
|
+
}, z.core.$strip>;
|
|
5
|
+
export declare const Erc20InitDataParams: z.ZodObject<{
|
|
6
|
+
tokenName: z.ZodString;
|
|
7
|
+
tokenSymbol: z.ZodString;
|
|
8
|
+
cap: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
|
|
9
|
+
defaultAdmin: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
10
|
+
minter: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
|
|
11
|
+
}, z.core.$strip>;
|
|
12
|
+
export declare const GetErc20InitData: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
13
|
+
"/": {
|
|
14
|
+
$post: {
|
|
15
|
+
input: {
|
|
16
|
+
json: {
|
|
17
|
+
tokenName: string;
|
|
18
|
+
tokenSymbol: string;
|
|
19
|
+
cap: string;
|
|
20
|
+
defaultAdmin: string;
|
|
21
|
+
minter: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
output: {
|
|
25
|
+
data: `0x${string}`;
|
|
26
|
+
};
|
|
27
|
+
outputFormat: "json";
|
|
28
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
}, "/", "/">>;
|
|
32
|
+
//# sourceMappingURL=getInitData.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getInitData.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc20/gatedSimple/getInitData.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,qBAAqB;;iBAIC,CAAC;AAEpC,eAAO,MAAM,mBAAmB;;;;;;iBAQC,CAAC;AAkBlC,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;aAc3B,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { encodeFunctionData } from "viem";
|
|
4
|
+
import { z } from "zod";
|
|
5
|
+
import { erc20GatedAbi } from "@evergonlabs/tmi-protocol-contracts/erc20Gated";
|
|
6
|
+
import { createController } from "../../../common/controller.js";
|
|
7
|
+
import { AddressSchema, HexStringSchema } from "../../../common/index.js";
|
|
8
|
+
import { Int256BigInt } from "../../../common/int256.js";
|
|
9
|
+
import { DEFAULT_COMPILOT_SIGNER } from "../../../common/models/compilot.js";
|
|
10
|
+
export const Erc20InitDataResponse = z
|
|
11
|
+
.object({
|
|
12
|
+
data: HexStringSchema.openapi("Init function call data in hex format"),
|
|
13
|
+
})
|
|
14
|
+
.openapi("Erc20InitDataResponse");
|
|
15
|
+
export const Erc20InitDataParams = z
|
|
16
|
+
.object({
|
|
17
|
+
tokenName: z.string().nonempty(),
|
|
18
|
+
tokenSymbol: z.string().nonempty(),
|
|
19
|
+
cap: Int256BigInt().openapi("Max. token supply"),
|
|
20
|
+
defaultAdmin: AddressSchema,
|
|
21
|
+
minter: AddressSchema,
|
|
22
|
+
})
|
|
23
|
+
.openapi("ERC20InitDataParams");
|
|
24
|
+
const getErc20InitDataRoute = describeRoute({
|
|
25
|
+
summary: "Get ERC20 Init Data",
|
|
26
|
+
description: `Returns init function call data in hex format. This is useful for using as initData in TransparentUpgradeableProxy`,
|
|
27
|
+
tags: ["Issuance"],
|
|
28
|
+
responses: {
|
|
29
|
+
200: {
|
|
30
|
+
description: "Init function call data in hex format",
|
|
31
|
+
content: {
|
|
32
|
+
"application/json": {
|
|
33
|
+
schema: resolver(Erc20InitDataResponse),
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
export const GetErc20InitData = createController({
|
|
40
|
+
build: (factory) => factory.createApp().post("/", getErc20InitDataRoute, validator("json", Erc20InitDataParams), async (c) => {
|
|
41
|
+
const data = c.req.valid("json");
|
|
42
|
+
const initData = encodeFunctionData({
|
|
43
|
+
abi: erc20GatedAbi,
|
|
44
|
+
functionName: "init",
|
|
45
|
+
args: [data.tokenName, data.tokenSymbol, data.cap, data.defaultAdmin, data.minter, DEFAULT_COMPILOT_SIGNER],
|
|
46
|
+
});
|
|
47
|
+
return c.json({
|
|
48
|
+
data: initData,
|
|
49
|
+
});
|
|
50
|
+
}),
|
|
51
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const ParseGatedSimpleErc20DeployEvent: 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
|
+
contractAddress: `0x${string}`;
|
|
12
|
+
};
|
|
13
|
+
outputFormat: "json";
|
|
14
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
}, "/", "/">>;
|
|
18
|
+
//# sourceMappingURL=parseDeployEvent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parseDeployEvent.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc20/gatedSimple/parseDeployEvent.ts"],"names":[],"mappings":"AAyBA,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;aAuC3C,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { describeRoute } from "hono-openapi";
|
|
2
|
+
import { resolver, validator } from "hono-openapi";
|
|
3
|
+
import { waitForTransactionReceipt } from "viem/actions";
|
|
4
|
+
import { z } from "zod";
|
|
5
|
+
import { getPublicClient } from "../../../common/blockchain.js";
|
|
6
|
+
import { createController } from "../../../common/controller.js";
|
|
7
|
+
import { HttpError } from "../../../common/http-error.js";
|
|
8
|
+
import { AddressSchema, HashSchema } from "../../../common/index.js";
|
|
9
|
+
import { FactoryChainIdQuery } from "../../common/factories.js";
|
|
10
|
+
const QuerySchema = z.object({
|
|
11
|
+
chainId: FactoryChainIdQuery.openapi({
|
|
12
|
+
param: {
|
|
13
|
+
name: "chainId",
|
|
14
|
+
in: "query",
|
|
15
|
+
},
|
|
16
|
+
}),
|
|
17
|
+
hash: HashSchema.openapi({
|
|
18
|
+
param: {
|
|
19
|
+
name: "hash",
|
|
20
|
+
in: "query",
|
|
21
|
+
},
|
|
22
|
+
}),
|
|
23
|
+
});
|
|
24
|
+
export const ParseGatedSimpleErc20DeployEvent = createController({
|
|
25
|
+
build: (factory) => factory.createApp().get("/", describeRoute({
|
|
26
|
+
summary: "Get Gated Simple ERC20 Deploy Event",
|
|
27
|
+
description: `Gets the contract deployment transaction by hash and extracts the deployed contract address from the receipt.
|
|
28
|
+
|
|
29
|
+
Provided transaction must be a contract creation transaction for the gated simple ERC20 token.`,
|
|
30
|
+
tags: ["Issuance"],
|
|
31
|
+
responses: {
|
|
32
|
+
200: {
|
|
33
|
+
description: "Returns the deployed contract address",
|
|
34
|
+
content: {
|
|
35
|
+
"application/json": {
|
|
36
|
+
schema: resolver(z.object({
|
|
37
|
+
contractAddress: AddressSchema,
|
|
38
|
+
})),
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
}), validator("query", QuerySchema), async (c) => {
|
|
44
|
+
const params = c.req.valid("query");
|
|
45
|
+
const receipt = await waitForTransactionReceipt(getPublicClient(params.chainId, c.env.config), {
|
|
46
|
+
hash: params.hash,
|
|
47
|
+
});
|
|
48
|
+
if (!receipt.contractAddress) {
|
|
49
|
+
throw new UnableParseGatedSimpleErc20DeployEvent();
|
|
50
|
+
}
|
|
51
|
+
return c.json({
|
|
52
|
+
contractAddress: receipt.contractAddress,
|
|
53
|
+
});
|
|
54
|
+
}),
|
|
55
|
+
});
|
|
56
|
+
class UnableParseGatedSimpleErc20DeployEvent extends HttpError {
|
|
57
|
+
constructor() {
|
|
58
|
+
super(500, {
|
|
59
|
+
message: `Can't extract contract address from transaction receipt. Make sure you're passing a contract creation transaction for the gated simple ERC20 token`,
|
|
60
|
+
name: "UnableParseGatedSimpleErc20DeployEvent",
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grantRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/grantRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,2BAA2B;;;;iBAOtC,CAAC;AAkBH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"grantRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/grantRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,2BAA2B;;;;iBAOtC,CAAC;AAkBH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;aAczB,CAAC"}
|
|
@@ -26,6 +26,54 @@ export declare const Erc20Controller: import("../../common/controller.js").ICont
|
|
|
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
|
+
cap: 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
|
+
supplyCap: string;
|
|
69
|
+
name: string;
|
|
70
|
+
symbol: 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 Erc20Controller: import("../../common/controller.js").ICont
|
|
|
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
|
+
cap: 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,55 @@ export declare const Erc20Controller: import("../../common/controller.js").ICont
|
|
|
74
150
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
75
151
|
};
|
|
76
152
|
};
|
|
77
|
-
}, "/
|
|
153
|
+
}, "/getDeployEventGated"> | import("hono/types").MergeSchemaPath<{
|
|
154
|
+
"/": {
|
|
155
|
+
$get: {
|
|
156
|
+
input: {};
|
|
157
|
+
output: {
|
|
158
|
+
bytecode: `0x${string}`;
|
|
159
|
+
abi: any[];
|
|
160
|
+
args?: any[] | undefined;
|
|
161
|
+
};
|
|
162
|
+
outputFormat: "json";
|
|
163
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
164
|
+
};
|
|
165
|
+
};
|
|
166
|
+
}, "/deployGatedSimple"> | import("hono/types").MergeSchemaPath<{
|
|
167
|
+
"/": {
|
|
168
|
+
$post: {
|
|
169
|
+
input: {
|
|
170
|
+
json: {
|
|
171
|
+
tokenName: string;
|
|
172
|
+
tokenSymbol: string;
|
|
173
|
+
cap: string;
|
|
174
|
+
defaultAdmin: string;
|
|
175
|
+
minter: string;
|
|
176
|
+
};
|
|
177
|
+
};
|
|
178
|
+
output: {
|
|
179
|
+
data: `0x${string}`;
|
|
180
|
+
};
|
|
181
|
+
outputFormat: "json";
|
|
182
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
183
|
+
};
|
|
184
|
+
};
|
|
185
|
+
}, "/getInitData"> | import("hono/types").MergeSchemaPath<{
|
|
186
|
+
"/": {
|
|
187
|
+
$get: {
|
|
188
|
+
input: {
|
|
189
|
+
query: {
|
|
190
|
+
chainId: string | string[];
|
|
191
|
+
hash: string | string[];
|
|
192
|
+
};
|
|
193
|
+
};
|
|
194
|
+
output: {
|
|
195
|
+
contractAddress: `0x${string}`;
|
|
196
|
+
};
|
|
197
|
+
outputFormat: "json";
|
|
198
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
199
|
+
};
|
|
200
|
+
};
|
|
201
|
+
}, "/getDeployEventGatedSimple"> | import("hono/types").MergeSchemaPath<{
|
|
78
202
|
"/": {
|
|
79
203
|
$post: {
|
|
80
204
|
input: {
|
|
@@ -292,33 +416,5 @@ export declare const Erc20Controller: import("../../common/controller.js").ICont
|
|
|
292
416
|
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
293
417
|
};
|
|
294
418
|
};
|
|
295
|
-
}, "/renounceRole"
|
|
296
|
-
"/": {
|
|
297
|
-
$post: {
|
|
298
|
-
input: {
|
|
299
|
-
json: {
|
|
300
|
-
tokenAddress: string;
|
|
301
|
-
name: string;
|
|
302
|
-
symbol: string;
|
|
303
|
-
cap: string;
|
|
304
|
-
defaultAdmin: string;
|
|
305
|
-
minter: string;
|
|
306
|
-
gatingSigner?: string | undefined;
|
|
307
|
-
};
|
|
308
|
-
};
|
|
309
|
-
output: {
|
|
310
|
-
data: `0x${string}`;
|
|
311
|
-
to: `0x${string}`;
|
|
312
|
-
details: {
|
|
313
|
-
functionName: string;
|
|
314
|
-
address: `0x${string}`;
|
|
315
|
-
abi: any[];
|
|
316
|
-
args: any[];
|
|
317
|
-
};
|
|
318
|
-
};
|
|
319
|
-
outputFormat: "json";
|
|
320
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
321
|
-
};
|
|
322
|
-
};
|
|
323
|
-
}, "/initialize">, "/">>;
|
|
419
|
+
}, "/renounceRole">, "/", "/">>;
|
|
324
420
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/index.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+BA0B1B,CAAC"}
|
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
import { createController } from "../../common/controller.js";
|
|
2
|
+
import { CreateErc20Token } from "./default/deploy.js";
|
|
3
|
+
import { InitializeDefaultErc20 } from "./default/initialize.js";
|
|
4
|
+
import { ParseDefaultErc20DeployEvent } from "./default/parseDeployEvent.js";
|
|
5
|
+
import { CreateGatedErc20Token } from "./gated/deploy.js";
|
|
6
|
+
import { InitializeGatedErc20 } from "./gated/initialize.js";
|
|
7
|
+
import { ParseGatedErc20DeployEvent } from "./gated/parseDeployEvent.js";
|
|
8
|
+
import { DeployErc20GatedSimpleToken } from "./gatedSimple/deploy.js";
|
|
9
|
+
import { GetErc20InitData } from "./gatedSimple/getInitData.js";
|
|
10
|
+
import { ParseGatedSimpleErc20DeployEvent } from "./gatedSimple/parseDeployEvent.js";
|
|
2
11
|
import { ApproveErc20Token } from "./approve.js";
|
|
3
12
|
import { BurnErc20Token } from "./burn.js";
|
|
4
|
-
import { CreateErc20Token } from "./deploy.js";
|
|
5
|
-
import { CreateGatedErc20Token } from "./deployGated.js";
|
|
6
13
|
import { GrantRoleErc20 } from "./grantRole.js";
|
|
7
|
-
import { InitializeErc20 } from "./initialize.js";
|
|
8
14
|
import { MintErc20Token } from "./mint.js";
|
|
9
|
-
import { ParseErc20DeployEvent } from "./parseErc20DeployEvent.js";
|
|
10
15
|
import { RecoverErc20 } from "./recover.js";
|
|
11
16
|
import { RenounceRoleErc20 } from "./renounceRole.js";
|
|
12
17
|
import { RevokeRoleErc20 } from "./revokeRole.js";
|
|
@@ -15,9 +20,19 @@ import { TransferFromErc20 } from "./transferFrom.js";
|
|
|
15
20
|
export const Erc20Controller = createController({
|
|
16
21
|
build: (factory) => factory
|
|
17
22
|
.createApp()
|
|
23
|
+
// Default (non-gated) variant
|
|
18
24
|
.route("/deploy", CreateErc20Token.build(factory))
|
|
25
|
+
.route("/initialize", InitializeDefaultErc20.build(factory))
|
|
26
|
+
.route("/getDeployEvent", ParseDefaultErc20DeployEvent.build(factory))
|
|
27
|
+
// Gated variant
|
|
19
28
|
.route("/deployGated", CreateGatedErc20Token.build(factory))
|
|
20
|
-
.route("/
|
|
29
|
+
.route("/initializeGated", InitializeGatedErc20.build(factory))
|
|
30
|
+
.route("/getDeployEventGated", ParseGatedErc20DeployEvent.build(factory))
|
|
31
|
+
// Gated Simple (audited) variant
|
|
32
|
+
.route("/deployGatedSimple", DeployErc20GatedSimpleToken.build(factory))
|
|
33
|
+
.route("/getInitData", GetErc20InitData.build(factory))
|
|
34
|
+
.route("/getDeployEventGatedSimple", ParseGatedSimpleErc20DeployEvent.build(factory))
|
|
35
|
+
// Common actions
|
|
21
36
|
.route("/approve", ApproveErc20Token.build(factory))
|
|
22
37
|
.route("/burn", BurnErc20Token.build(factory))
|
|
23
38
|
.route("/mint", MintErc20Token.build(factory))
|
|
@@ -26,6 +41,5 @@ export const Erc20Controller = createController({
|
|
|
26
41
|
.route("/recover", RecoverErc20.build(factory))
|
|
27
42
|
.route("/grantRole", GrantRoleErc20.build(factory))
|
|
28
43
|
.route("/revokeRole", RevokeRoleErc20.build(factory))
|
|
29
|
-
.route("/renounceRole", RenounceRoleErc20.build(factory))
|
|
30
|
-
.route("/initialize", InitializeErc20.build(factory)),
|
|
44
|
+
.route("/renounceRole", RenounceRoleErc20.build(factory)),
|
|
31
45
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mint.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/mint.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,sBAAsB;;;;iBAIjC,CAAC;AAkBH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"mint.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/mint.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,sBAAsB;;;;iBAIjC,CAAC;AAkBH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;aAczB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"recover.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/recover.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,yBAAyB;;;;;iBAKpC,CAAC;AAmBH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"recover.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/recover.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,yBAAyB;;;;;iBAKpC,CAAC;AAmBH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;aAcvB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"renounceRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/renounceRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,8BAA8B;;;;iBAOzC,CAAC;AAkBH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"renounceRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/renounceRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,8BAA8B;;;;iBAOzC,CAAC;AAkBH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;aAc5B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"revokeRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/revokeRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,4BAA4B;;;;iBAOvC,CAAC;AAkBH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"revokeRole.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/revokeRole.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAqB,cAAc,EAAE,MAAM,yCAAyC,CAAC;AAE5F,eAAO,MAAM,4BAA4B;;;;iBAOvC,CAAC;AAkBH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;aAc1B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transfer.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/transfer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,0BAA0B;;;;iBAIrC,CAAC;AAkBH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"transfer.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/transfer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,0BAA0B;;;;iBAIrC,CAAC;AAkBH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;aAcxB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transferFrom.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/transferFrom.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,8BAA8B;;;;;iBAKzC,CAAC;AAmBH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"transferFrom.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc20/transferFrom.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,8BAA8B;;;;;iBAKzC,CAAC;AAmBH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;aAc5B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approve.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/approve.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,0BAA0B;;;;iBAIrC,CAAC;AAkBH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"approve.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/approve.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,0BAA0B;;;;iBAIrC,CAAC;AAkBH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;aAcxB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"burn.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/burn.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,uBAAuB;;;iBAGlC,CAAC;AAkBH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"burn.d.ts","sourceRoot":"","sources":["../../../src/issuance/erc721/burn.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,uBAAuB;;;iBAGlC,CAAC;AAkBH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;aAcrB,CAAC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const DeployErc721RequestSchema: 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
|
+
}, z.core.$strip>;
|
|
10
|
+
export declare const CreateErc721Token: import("../../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../../common/context.js").AppContext, {
|
|
11
|
+
"/": {
|
|
12
|
+
$post: {
|
|
13
|
+
input: {
|
|
14
|
+
json: {
|
|
15
|
+
chainId: 11155111 | 72080;
|
|
16
|
+
tokenName: string;
|
|
17
|
+
tokenSymbol: string;
|
|
18
|
+
baseURI: string;
|
|
19
|
+
defaultTokenAdmin: 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=deploy.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deploy.d.ts","sourceRoot":"","sources":["../../../../src/issuance/erc721/default/deploy.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,eAAO,MAAM,yBAAyB;;;;;;;iBAOpC,CAAC;AA6BH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;aAc5B,CAAC"}
|
|
@@ -0,0 +1,53 @@
|
|
|
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 { FactoryChainId, getFactories } from "../../common/factories.js";
|
|
8
|
+
export const DeployErc721RequestSchema = z.object({
|
|
9
|
+
chainId: FactoryChainId.Schema,
|
|
10
|
+
tokenName: z.string().nonempty().openapi({ description: "Name of the NFT collection" }),
|
|
11
|
+
tokenSymbol: z.string().nonempty().openapi({ description: "Symbol of the NFT collection" }),
|
|
12
|
+
baseURI: z.string().openapi({ description: "Base URI for token metadata" }),
|
|
13
|
+
defaultTokenAdmin: AddressSchema.openapi({ description: "Address to receive DEFAULT_ADMIN_ROLE" }),
|
|
14
|
+
minter: AddressSchema.openapi({ description: "Address to receive MINTER_ROLE" }),
|
|
15
|
+
});
|
|
16
|
+
const deployErc721Route = describeRoute({
|
|
17
|
+
summary: "Deploy ERC721 via Factory",
|
|
18
|
+
description: `This contract has not been audited.
|
|
19
|
+
|
|
20
|
+
Returns transaction data for deploying a new ERC721 token via the factory contract.
|
|
21
|
+
|
|
22
|
+
Calls deployAndInitializeProxy on the ERC721PausableRecoverableFactory to atomically deploy and initialize a new token proxy.
|
|
23
|
+
|
|
24
|
+
The deployed token supports:
|
|
25
|
+
- mint(to, tokenId) - Mint token (MINTER_ROLE gated)
|
|
26
|
+
- burn(tokenId) - Burn token (owner, approved, or MINTER_ROLE)
|
|
27
|
+
- setBaseURI(uri) - Set base URI (URI_SETTER_ROLE gated)
|
|
28
|
+
- setTokenURI(tokenId, uri) - Set token-specific URI (URI_SETTER_ROLE gated)
|
|
29
|
+
- setContractURI(uri) - Set contract metadata URI (URI_SETTER_ROLE gated)`,
|
|
30
|
+
tags: ["Issuance"],
|
|
31
|
+
responses: {
|
|
32
|
+
200: {
|
|
33
|
+
description: "Returns transaction data for deploying an ERC721 token via factory",
|
|
34
|
+
content: {
|
|
35
|
+
"application/json": {
|
|
36
|
+
schema: resolver(TransactionSchema),
|
|
37
|
+
},
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
});
|
|
42
|
+
export const CreateErc721Token = createController({
|
|
43
|
+
build: (factory) => factory.createApp().post("/", deployErc721Route, validator("json", DeployErc721RequestSchema), async (c) => {
|
|
44
|
+
const { chainId, tokenName, tokenSymbol, baseURI, defaultTokenAdmin, minter } = c.req.valid("json");
|
|
45
|
+
const factory = getFactories(chainId);
|
|
46
|
+
return c.json(toTransaction({
|
|
47
|
+
address: factory.ERC721PausableRecoverableFactory,
|
|
48
|
+
abi: abis.erc721PausableRecoverableFactoryAbi,
|
|
49
|
+
functionName: "deployAndInitializeProxy",
|
|
50
|
+
args: [tokenName, tokenSymbol, baseURI, defaultTokenAdmin, minter],
|
|
51
|
+
}));
|
|
52
|
+
}),
|
|
53
|
+
});
|