@merkl/api 0.18.0 → 0.18.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/database/api/seeder/resources/protocol.d.ts +48 -48
- package/dist/src/backgroundJobs/index.js +8 -7
- package/dist/src/backgroundJobs/jobs/campaignsCacheUpdater.js +11 -11
- package/dist/src/backgroundJobs/jobs/health.js +1 -1
- package/dist/src/backgroundJobs/jobs/opportunityUpdater.js +2 -1
- package/dist/src/cache/index.js +2 -2
- package/dist/src/cache/redis.js +1 -1
- package/dist/src/eden/index.d.ts +1014 -919
- package/dist/src/entities/campaign.js +1 -1
- package/dist/src/errors/VoidString.error.d.ts +4 -0
- package/dist/src/errors/VoidString.error.js +7 -0
- package/dist/src/factories/dynamicData/factory.d.ts +0 -0
- package/dist/src/factories/dynamicData/factory.js +10 -0
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/factory.js +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ajna.d.ts +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ajna.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ambiant.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ambiant.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Badger.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Badger.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Clamm.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Clamm.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Compound.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Compound.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Default.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Default.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Dolomite.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Dolomite.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/EigenLayer.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/EigenLayer.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Encompassing.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Encompassing.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Erc20.d.ts +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Erc20.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Erc20Snapshot.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Erc20Snapshot.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Euler.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Euler.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/EventBased.d.ts +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/EventBased.js +5 -5
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Hyperdrive.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Hyperdrive.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Invalid.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Invalid.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ion.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Ion.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/JsonAirdrop.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/JsonAirdrop.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Morpho.d.ts +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Morpho.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Radiant.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Radiant.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Silo.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Silo.js +2 -2
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/UniswapV4.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/UniswapV4.js +3 -3
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Vest.d.ts +1 -1
- package/dist/src/factories/{metadataFactory → opportunityMetadata}/implementations/Vest.js +3 -3
- package/dist/src/guards/BackOffice.guard.js +1 -1
- package/dist/src/guards/Engine.guard.js +1 -1
- package/dist/src/guards/TokenAuth.guard.js +1 -1
- package/dist/src/index.d.ts +211 -186
- package/dist/src/jobs/etl/dynamic-data.js +1 -1
- package/dist/src/jobs/etl/pendings.js +5 -4
- package/dist/src/jobs/etl/prices.js +3 -3
- package/dist/src/jobs/etl/reward-breakdowns.js +3 -3
- package/dist/src/jobs/etl/rewards.js +2 -2
- package/dist/src/jobs/etl/update-dynamic-data.js +4 -4
- package/dist/src/jobs/etl/update-euler-vaults.d.ts +1 -0
- package/dist/src/jobs/etl/update-euler-vaults.js +122 -0
- package/dist/src/libs/campaigns/campaignTypes/AjnaDynamicData.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/BadgerDynamicData.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/CLAMMDynamicData.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20DynamicData.js +4 -4
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/GenericProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/GenericProcessor.js +4 -4
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AaveProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AaveProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AnglesLiquid.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AnglesLiquid.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AssetProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AssetProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AuraProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/AuraProcessor.js +3 -3
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerGaugeProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerGaugeProcessor.js +3 -3
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerPoolProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerPoolProcessor.js +3 -3
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerV3PoolProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BalancerV3PoolProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BeefyProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/BeefyProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/CompoundProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/CompoundProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/ERC4626Processor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/ERC4626Processor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EnzymeProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EnzymeProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EqualizerGaugeProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EqualizerGaugeProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EulerBorrowProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EulerBorrowProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EulerLendProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/EulerLendProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/FluidProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/FluidProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/FraxProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/FraxProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/GammaProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/GammaProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/GearboxProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/GearboxProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HanjiVaultProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HanjiVaultProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HoldStationProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HoldStationProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HourglassProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/HourglassProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/MaverickBPProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/MaverickBPProcessor.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/MetamorphoProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/MetamorphoProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/NoLinkVaultProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/NoLinkVaultProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/PendleProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/PendleProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/PendleYTProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/PendleYTProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/RadiantProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/RadiantProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/RfxProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/RfxProcessor.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/Satlayer.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/Satlayer.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SpectraProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SpectraProcessor.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SpectraYTProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SpectraYTProcessor.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SpliceProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SturdySiloProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/SturdySiloProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/TempestVaultProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/TempestVaultProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/TemplateProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/TorosProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/TorosProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/UniswapProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/UniswapProcessor.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/VicunaProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/VicunaProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/WoofiProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/WoofiProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/ZkSwapThreePoolProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/ZkSwapThreePoolProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/curveNPoolProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/curveNPoolProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/curveProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/curveProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/stakedCurveProcessor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/stakedCurveProcessor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/xU308Processor.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/implementations/xU308Processor.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesPrices.d.ts +1 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound1.js +1 -1
- package/dist/src/libs/campaigns/campaignTypes/EventBasedDynamicData.js +14 -17
- package/dist/src/libs/campaigns/campaignTypes/RadiantDynamicData.js +2 -2
- package/dist/src/libs/campaigns/campaignTypes/UniswapV4DynamicData.js +2 -2
- package/dist/src/libs/campaigns/campaignsDynamicData.js +1 -1
- package/dist/src/libs/campaigns/utils/fetchClamInfo.d.ts +1 -1
- package/dist/src/libs/campaigns/utils/fetchLogs.js +1 -1
- package/dist/src/libs/campaigns/utils/getCompV2ForksVaults.js +4 -4
- package/dist/src/libs/campaigns/utils/getContractCreationBlock.js +1 -1
- package/dist/src/libs/campaigns/utils/getDolomiteMarkets.js +1 -1
- package/dist/src/libs/campaigns/utils/getEulerV2Vaults.js +5 -5
- package/dist/src/libs/campaigns/utils/getUniswapV4Pools.js +4 -4
- package/dist/src/libs/deprecated-merklv3/index.d.ts +1 -1
- package/dist/src/libs/deprecated-merklv3/index.js +2 -2
- package/dist/src/libs/getTokensList.js +1 -1
- package/dist/src/libs/merklChainData.js +2 -2
- package/dist/src/libs/parse/marketsWithCache.js +2 -2
- package/dist/src/libs/positions/ajna/index.js +1 -1
- package/dist/src/libs/positions/badger/index.js +2 -2
- package/dist/src/libs/positions/clamm/index.js +3 -3
- package/dist/src/libs/positions/clamm/thegraph/fetchFarmedPositions.js +1 -1
- package/dist/src/libs/staticCampaigns.js +2 -2
- package/dist/src/libs/tokens/balances.js +1 -1
- package/dist/src/libs/tokens/tokenInfo.d.ts +1 -1
- package/dist/src/modules/v4/accounting/accounting.controller.js +3 -3
- package/dist/src/modules/v4/accounting/accounting.repository.d.ts +1 -1
- package/dist/src/modules/v4/accounting/accounting.repository.js +1 -1
- package/dist/src/modules/v4/accounting/accounting.service.d.ts +1 -1
- package/dist/src/modules/v4/accounting/accounting.service.js +2 -2
- package/dist/src/modules/v4/airflow/airflow.service.js +1 -1
- package/dist/src/modules/v4/apr/apr.model.d.ts +1 -1
- package/dist/src/modules/v4/apr/apr.model.js +1 -1
- package/dist/src/modules/v4/apr/apr.service.js +1 -1
- package/dist/src/modules/v4/blacklist/blacklist.controller.js +2 -2
- package/dist/src/modules/v4/blacklist/blacklist.repository.js +1 -1
- package/dist/src/modules/v4/boost/boost.controller.d.ts +1 -1
- package/dist/src/modules/v4/cache/cache.repository.js +1 -1
- package/dist/src/modules/v4/cache/cache.service.js +1 -1
- package/dist/src/modules/v4/campaign/campaign.controller.d.ts +23 -23
- package/dist/src/modules/v4/campaign/campaign.controller.js +4 -4
- package/dist/src/modules/v4/campaign/campaign.model.d.ts +2 -2
- package/dist/src/modules/v4/campaign/campaign.model.js +2 -2
- package/dist/src/modules/v4/campaign/campaign.repository.d.ts +60 -46
- package/dist/src/modules/v4/campaign/campaign.repository.js +6 -5
- package/dist/src/modules/v4/campaign/campaign.service.d.ts +69 -55
- package/dist/src/modules/v4/campaign/campaign.service.js +9 -9
- package/dist/src/modules/v4/chain/chain.controller.d.ts +10 -10
- package/dist/src/modules/v4/chain/chain.controller.js +1 -1
- package/dist/src/modules/v4/chain/chain.model.d.ts +1 -1
- package/dist/src/modules/v4/chain/chain.model.js +1 -1
- package/dist/src/modules/v4/chain/chain.repository.d.ts +11 -11
- package/dist/src/modules/v4/chain/chain.repository.js +1 -1
- package/dist/src/modules/v4/chain/chain.service.d.ts +10 -10
- package/dist/src/modules/v4/claims/claims.controller.js +1 -1
- package/dist/src/modules/v4/computedValue/computedValue.controller.d.ts +1 -1
- package/dist/src/modules/v4/computedValue/computedValue.controller.js +2 -2
- package/dist/src/modules/v4/computedValue/computedValue.repository.d.ts +1 -1
- package/dist/src/modules/v4/computedValue/computedValue.repository.js +1 -1
- package/dist/src/modules/v4/computedValue/computedValue.service.d.ts +1 -1
- package/dist/src/modules/v4/computedValue/computedValue.service.js +1 -1
- package/dist/src/modules/v4/creator/creator.controller.d.ts +5 -5
- package/dist/src/modules/v4/creator/creator.controller.js +2 -2
- package/dist/src/modules/v4/creator/creator.model.d.ts +1 -1
- package/dist/src/modules/v4/creator/creator.repository.d.ts +5 -5
- package/dist/src/modules/v4/creator/creator.repository.js +1 -1
- package/dist/src/modules/v4/creator/creator.service.d.ts +4 -4
- package/dist/src/modules/v4/dynamicData/dynamicData.controller.js +1 -1
- package/dist/src/modules/v4/dynamicData/dynamicData.model.d.ts +1 -1
- package/dist/src/modules/v4/dynamicData/dynamicData.service.js +6 -7
- package/dist/src/modules/v4/enso/enso.model.d.ts +40 -40
- package/dist/src/modules/v4/enso/enso.service.d.ts +3 -3
- package/dist/src/modules/v4/enso/enso.service.js +2 -2
- package/dist/src/modules/v4/explorer/explorer.controller.d.ts +2 -2
- package/dist/src/modules/v4/explorer/explorer.controller.js +1 -1
- package/dist/src/modules/v4/explorer/explorer.model.js +1 -1
- package/dist/src/modules/v4/explorer/explorer.repository.d.ts +5 -5
- package/dist/src/modules/v4/explorer/explorer.repository.js +1 -1
- package/dist/src/modules/v4/explorer/explorer.service.d.ts +6 -6
- package/dist/src/modules/v4/interaction/interaction.controller.d.ts +1 -1
- package/dist/src/modules/v4/interaction/interaction.model.d.ts +2 -2
- package/dist/src/modules/v4/interaction/interaction.service.d.ts +1 -1
- package/dist/src/modules/v4/interaction/interaction.service.js +3 -3
- package/dist/src/modules/v4/kyberzap/kyberzap.model.d.ts +22 -22
- package/dist/src/modules/v4/kyberzap/kyberzap.service.d.ts +1 -1
- package/dist/src/modules/v4/kyberzap/kyberzap.service.js +1 -1
- package/dist/src/modules/v4/liquidity/implementations/BadgerPositionFetcher.js +1 -1
- package/dist/src/modules/v4/liquidity/implementations/ClammPositionFetcher.js +1 -1
- package/dist/src/modules/v4/liquidity/liquidity.controller.js +1 -1
- package/dist/src/modules/v4/liquidity/liquidity.service.js +1 -1
- package/dist/src/modules/v4/merklRoot/index.d.ts +3 -3
- package/dist/src/modules/v4/merklRoot/index.js +3 -3
- package/dist/src/modules/v4/merklRoot/merklRoot.controller.js +2 -2
- package/dist/src/modules/v4/merklRoot/merklRoot.repository.js +1 -1
- package/dist/src/modules/v4/opportunity/opportunity.controller.d.ts +81 -81
- package/dist/src/modules/v4/opportunity/opportunity.controller.js +3 -3
- package/dist/src/modules/v4/opportunity/opportunity.converter.js +2 -2
- package/dist/src/modules/v4/opportunity/opportunity.model.d.ts +11 -11
- package/dist/src/modules/v4/opportunity/opportunity.model.js +7 -7
- package/dist/src/modules/v4/opportunity/opportunity.repository.d.ts +128 -114
- package/dist/src/modules/v4/opportunity/opportunity.repository.js +13 -5
- package/dist/src/modules/v4/opportunity/opportunity.service.d.ts +106 -106
- package/dist/src/modules/v4/opportunity/opportunity.service.js +11 -11
- package/dist/src/modules/v4/opportunity/validate-id.pipe.js +1 -1
- package/dist/src/modules/v4/price/price.controller.d.ts +8 -8
- package/dist/src/modules/v4/price/price.controller.js +2 -2
- package/dist/src/modules/v4/price/price.model.js +1 -1
- package/dist/src/modules/v4/price/price.repository.d.ts +10 -10
- package/dist/src/modules/v4/price/price.repository.js +1 -1
- package/dist/src/modules/v4/price/price.service.d.ts +8 -8
- package/dist/src/modules/v4/price/price.service.js +3 -3
- package/dist/src/modules/v4/prisma/index.d.ts +1 -1
- package/dist/src/modules/v4/programPayload/programPayload.controller.js +2 -2
- package/dist/src/modules/v4/programPayload/programPayload.repository.d.ts +209 -21
- package/dist/src/modules/v4/programPayload/programPayload.repository.js +120 -62
- package/dist/src/modules/v4/programPayload/programPayload.service.js +4 -2
- package/dist/src/modules/v4/protocol/protocol.controller.d.ts +6 -6
- package/dist/src/modules/v4/protocol/protocol.controller.js +1 -1
- package/dist/src/modules/v4/protocol/protocol.model.d.ts +1 -1
- package/dist/src/modules/v4/protocol/protocol.repository.d.ts +10 -10
- package/dist/src/modules/v4/protocol/protocol.repository.js +1 -1
- package/dist/src/modules/v4/protocol/protocol.service.d.ts +2 -2
- package/dist/src/modules/v4/protocol/protocol.service.js +3 -3
- package/dist/src/modules/v4/referral/referral.controller.js +1 -1
- package/dist/src/modules/v4/reward/index.d.ts +2 -2
- package/dist/src/modules/v4/reward/index.js +2 -2
- package/dist/src/modules/v4/reward/reward.controller.d.ts +1 -1
- package/dist/src/modules/v4/reward/reward.controller.js +6 -6
- package/dist/src/modules/v4/reward/reward.model.d.ts +1 -1
- package/dist/src/modules/v4/reward/reward.repository.d.ts +10 -10
- package/dist/src/modules/v4/reward/reward.repository.js +4 -4
- package/dist/src/modules/v4/reward/reward.service.d.ts +56 -56
- package/dist/src/modules/v4/reward/reward.service.js +5 -3
- package/dist/src/modules/v4/router.d.ts +201 -181
- package/dist/src/modules/v4/router.js +23 -23
- package/dist/src/modules/v4/status/status.controller.d.ts +24 -4
- package/dist/src/modules/v4/status/status.controller.js +13 -3
- package/dist/src/modules/v4/status/status.model.d.ts +3 -0
- package/dist/src/modules/v4/status/status.model.js +2 -1
- package/dist/src/modules/v4/status/status.repository.d.ts +18 -10
- package/dist/src/modules/v4/status/status.repository.js +13 -3
- package/dist/src/modules/v4/status/status.service.d.ts +7 -6
- package/dist/src/modules/v4/status/status.service.js +15 -3
- package/dist/src/modules/v4/token/token.controller.d.ts +9 -9
- package/dist/src/modules/v4/token/token.controller.js +4 -4
- package/dist/src/modules/v4/token/token.model.d.ts +1 -1
- package/dist/src/modules/v4/token/token.repository.d.ts +3 -3
- package/dist/src/modules/v4/token/token.repository.js +3 -3
- package/dist/src/modules/v4/token/token.service.d.ts +11 -11
- package/dist/src/modules/v4/token/token.service.js +5 -5
- package/dist/src/modules/v4/tvl/tvl.model.d.ts +1 -1
- package/dist/src/modules/v4/tvl/tvl.model.js +1 -1
- package/dist/src/modules/v4/tvl/tvl.service.js +1 -1
- package/dist/src/modules/v4/uniswapV4/uniswapV4.service.js +3 -3
- package/dist/src/modules/v4/user/user.controller.d.ts +22 -22
- package/dist/src/modules/v4/user/user.controller.js +2 -2
- package/dist/src/modules/v4/user/user.model.d.ts +1 -1
- package/dist/src/modules/v4/user/user.model.js +1 -1
- package/dist/src/modules/v4/user/user.repository.js +1 -1
- package/dist/src/modules/v4/user/user.service.js +2 -2
- package/dist/src/plugins/error-handling.plugin.d.ts +1 -1
- package/dist/src/plugins/error-handling.plugin.js +2 -2
- package/dist/src/routes/v1/allowances.d.ts +2 -2
- package/dist/src/routes/v1/allowances.js +5 -5
- package/dist/src/routes/v1/balances.js +5 -5
- package/dist/src/routes/v1/prices.js +1 -1
- package/dist/src/routes/v1/tokens.js +1 -1
- package/dist/src/routes/v3/app.d.ts +7 -2
- package/dist/src/routes/v3/app.js +20 -10
- package/dist/src/routes/v3/blacklist.js +1 -1
- package/dist/src/routes/v3/campaign/delay.js +3 -3
- package/dist/src/routes/v3/campaignClaims.js +3 -3
- package/dist/src/routes/v3/campaignUnclaimed.js +1 -1
- package/dist/src/routes/v3/campaigns.js +6 -7
- package/dist/src/routes/v3/campaignsForMainParameter.js +2 -2
- package/dist/src/routes/v3/campaignsRewardsReport.d.ts +2 -2
- package/dist/src/routes/v3/campaignsRewardsReport.js +4 -6
- package/dist/src/routes/v3/compoundV2.js +1 -1
- package/dist/src/routes/v3/euler.js +1 -1
- package/dist/src/routes/v3/health.js +1 -1
- package/dist/src/routes/v3/lostyield.js +3 -3
- package/dist/src/routes/v3/merkl.js +1 -1
- package/dist/src/routes/v3/morphoMarkets.js +1 -1
- package/dist/src/routes/v3/morphoVaults.js +1 -1
- package/dist/src/routes/v3/multiChainPositions.js +1 -1
- package/dist/src/routes/v3/opportunity.d.ts +2 -2
- package/dist/src/routes/v3/opportunity.js +3 -4
- package/dist/src/routes/v3/overview.d.ts +2 -2
- package/dist/src/routes/v3/overview.js +2 -3
- package/dist/src/routes/v3/positions.d.ts +3 -4
- package/dist/src/routes/v3/positions.js +4 -5
- package/dist/src/routes/v3/radiant.js +1 -1
- package/dist/src/routes/v3/recipients.js +1 -1
- package/dist/src/routes/v3/rewards.js +2 -2
- package/dist/src/routes/v3/rewardsReport.js +1 -1
- package/dist/src/routes/v3/router.d.ts +11 -6
- package/dist/src/routes/v3/silo.js +1 -1
- package/dist/src/routes/v3/token.js +4 -4
- package/dist/src/routes/v3/twt/participants.js +55 -3
- package/dist/src/routes/v3/uniswapv4.js +1 -1
- package/dist/src/routes/v3/updates.js +2 -2
- package/dist/src/routes/v3/userRewards.js +5 -5
- package/dist/src/utils/encodeCalls.d.ts +1 -1
- package/dist/src/utils/encodeCalls.js +1 -1
- package/dist/src/utils/error.d.ts +1 -1
- package/dist/src/utils/error.js +1 -1
- package/dist/src/utils/generateCardName.d.ts +1 -1
- package/dist/src/utils/generateCardName.js +1 -1
- package/dist/src/utils/generateIcons.d.ts +1 -1
- package/dist/src/utils/generateIcons.js +2 -2
- package/dist/src/utils/lastBlockBefore.js +2 -2
- package/dist/src/utils/pricer.js +1 -1
- package/dist/src/utils/prices/priceFetcherFactory.d.ts +1 -1
- package/dist/src/utils/prices/priceFetcherFactory.js +1 -1
- package/dist/src/utils/prices/priceService.js +2 -2
- package/dist/src/utils/prices/services/coinGeckoService.d.ts +1 -1
- package/dist/src/utils/prices/services/coinGeckoService.js +1 -1
- package/dist/src/utils/prices/services/defillamaService.d.ts +1 -1
- package/dist/src/utils/prices/services/defillamaService.js +1 -1
- package/dist/src/utils/prices/services/dexScreenerService.d.ts +1 -1
- package/dist/src/utils/prices/services/dexScreenerService.js +1 -1
- package/dist/src/utils/prices/services/erc4626Service.d.ts +1 -1
- package/dist/src/utils/prices/services/erc4626Service.js +2 -2
- package/dist/src/utils/prices/services/indexCoopService.d.ts +1 -1
- package/dist/src/utils/prices/services/indexCoopService.js +1 -1
- package/dist/src/utils/prices/services/priceFetcher.d.ts +1 -1
- package/dist/src/utils/prisma.d.ts +3 -3
- package/dist/src/utils/prisma.js +2 -2
- package/dist/src/utils/queries/activeCampaigns.d.ts +1 -1
- package/dist/src/utils/queries/activeCampaigns.js +1 -1
- package/dist/src/utils/queries/allCampaigns.d.ts +1 -1
- package/dist/src/utils/queries/allCampaigns.js +1 -1
- package/dist/tsconfig.package.tsbuildinfo +1 -1
- package/package.json +3 -2
- package/dist/src/libs/campaigns/getCampaigns.d.ts +0 -1
- package/dist/src/libs/campaigns/getCampaigns.js +0 -18
- package/dist/src/libs/custom/twtParticipants.d.ts +0 -6
- package/dist/src/libs/custom/twtParticipants.js +0 -54
- package/dist/src/modules/v4/programPayload/index.d.ts +0 -3
- package/dist/src/modules/v4/programPayload/index.js +0 -3
- package/dist/src/modules/v4/status/index.d.ts +0 -2
- package/dist/src/modules/v4/status/index.js +0 -2
- package/dist/src/types/parameters/Action.d.ts +0 -4
- package/dist/src/types/parameters/Action.js +0 -11
- package/dist/src/types/parameters/Chain.d.ts +0 -4
- package/dist/src/types/parameters/Chain.js +0 -13
- package/dist/src/types/parameters/ChainCampaignId.d.ts +0 -4
- package/dist/src/types/parameters/ChainCampaignId.js +0 -13
- package/dist/src/types/parameters/MainParameter.d.ts +0 -4
- package/dist/src/types/parameters/MainParameter.js +0 -19
- package/dist/src/types/parameters/OpportunityId.d.ts +0 -4
- package/dist/src/types/parameters/OpportunityId.js +0 -14
- package/dist/src/types/parameters/Timestamp.d.ts +0 -4
- package/dist/src/types/parameters/Timestamp.js +0 -16
- package/dist/src/types/parameters/Type.d.ts +0 -4
- package/dist/src/types/parameters/Type.js +0 -15
- package/dist/src/types/parameters/index.d.ts +0 -36
- package/dist/src/types/parameters/index.js +0 -17
- /package/dist/src/factories/{metadataFactory → opportunityMetadata}/factory.d.ts +0 -0
@@ -1,5 +1,5 @@
|
|
1
|
-
import { AuthorizationHeadersDto, EngineGuard } from "
|
2
|
-
import { throwOnInvalidRequiredAddress } from "
|
1
|
+
import { AuthorizationHeadersDto, EngineGuard } from "@/guards/Engine.guard";
|
2
|
+
import { throwOnInvalidRequiredAddress } from "@/utils/throw";
|
3
3
|
import Elysia from "elysia";
|
4
4
|
import { GetCampaignComputedValue, GetUserComputedValues, UpsertCampaignComputedValue, UpsertUserComputedValues, } from "./computedValue.model";
|
5
5
|
import { ComputedValueService } from "./computedValue.service";
|
@@ -7,8 +7,8 @@ export declare abstract class ComputedValueRepository {
|
|
7
7
|
} | null>;
|
8
8
|
static upsertCampaignComputedValue(data: UpsertCampaignComputedValueModel): Promise<void>;
|
9
9
|
static findUserValues(data: GetUserComputedValuesModel): Promise<{
|
10
|
-
reason: string;
|
11
10
|
id: number;
|
11
|
+
reason: string;
|
12
12
|
campaignId: string;
|
13
13
|
boost: number | null;
|
14
14
|
}[]>;
|
@@ -7,8 +7,8 @@ export declare abstract class ComputedValueService {
|
|
7
7
|
} | null>;
|
8
8
|
static upsertCampaignComputedValue(data: UpsertCampaignComputedValueModel): Promise<void>;
|
9
9
|
static findUserValues(params: GetUserComputedValuesModel): Promise<{
|
10
|
-
reason: string;
|
11
10
|
id: number;
|
11
|
+
reason: string;
|
12
12
|
campaignId: string;
|
13
13
|
boost: number | null;
|
14
14
|
}[]>;
|
@@ -25,8 +25,8 @@ export declare const CreatorController: Elysia<"/creators", false, {
|
|
25
25
|
headers: unknown;
|
26
26
|
response: {
|
27
27
|
200: ({
|
28
|
-
name: string;
|
29
28
|
id: string;
|
29
|
+
name: string;
|
30
30
|
addresses: string[];
|
31
31
|
} & {
|
32
32
|
icon?: string | undefined;
|
@@ -47,8 +47,8 @@ export declare const CreatorController: Elysia<"/creators", false, {
|
|
47
47
|
headers: unknown;
|
48
48
|
response: {
|
49
49
|
200: {
|
50
|
-
name: string;
|
51
50
|
id: string;
|
51
|
+
name: string;
|
52
52
|
addresses: string[];
|
53
53
|
icon?: string | undefined;
|
54
54
|
};
|
@@ -62,8 +62,8 @@ export declare const CreatorController: Elysia<"/creators", false, {
|
|
62
62
|
post: {
|
63
63
|
body: {
|
64
64
|
icon?: string | undefined;
|
65
|
-
name: string;
|
66
65
|
id: string;
|
66
|
+
name: string;
|
67
67
|
addresses: string[];
|
68
68
|
};
|
69
69
|
params: {};
|
@@ -73,8 +73,8 @@ export declare const CreatorController: Elysia<"/creators", false, {
|
|
73
73
|
};
|
74
74
|
response: {
|
75
75
|
200: {
|
76
|
-
name: string;
|
77
76
|
id: string;
|
77
|
+
name: string;
|
78
78
|
icon: string | null;
|
79
79
|
};
|
80
80
|
};
|
@@ -99,8 +99,8 @@ export declare const CreatorController: Elysia<"/creators", false, {
|
|
99
99
|
};
|
100
100
|
response: {
|
101
101
|
200: {
|
102
|
-
name: string;
|
103
102
|
id: string;
|
103
|
+
name: string;
|
104
104
|
icon: string | null;
|
105
105
|
};
|
106
106
|
};
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { NotFoundError } from "
|
2
|
-
import { AuthorizationHeadersDto, BackOfficeGuard } from "
|
1
|
+
import { NotFoundError } from "@/errors";
|
2
|
+
import { AuthorizationHeadersDto, BackOfficeGuard } from "@/guards/BackOffice.guard";
|
3
3
|
import { Elysia } from "elysia";
|
4
4
|
import { CreatorDto, GetManyCreatorQuery, UpdateCreatorDto } from "./creator.model";
|
5
5
|
import { CreatorService } from "./creator.service";
|
@@ -7,13 +7,13 @@ export declare abstract class CreatorRepository {
|
|
7
7
|
creatorId: string | null;
|
8
8
|
}[];
|
9
9
|
} & {
|
10
|
-
name: string;
|
11
10
|
id: string;
|
11
|
+
name: string;
|
12
12
|
icon: string | null;
|
13
13
|
}) | null>;
|
14
14
|
static findUniqueFromAddress(address: string): Promise<{
|
15
|
-
name: string;
|
16
15
|
id: string;
|
16
|
+
name: string;
|
17
17
|
icon: string | null;
|
18
18
|
} | null>;
|
19
19
|
static findMany(query: GetManyCreatorModel): Promise<({
|
@@ -23,18 +23,18 @@ export declare abstract class CreatorRepository {
|
|
23
23
|
creatorId: string | null;
|
24
24
|
}[];
|
25
25
|
} & {
|
26
|
-
name: string;
|
27
26
|
id: string;
|
27
|
+
name: string;
|
28
28
|
icon: string | null;
|
29
29
|
})[]>;
|
30
30
|
static create({ addresses, ...creator }: Creator["model"]): Promise<{
|
31
|
-
name: string;
|
32
31
|
id: string;
|
32
|
+
name: string;
|
33
33
|
icon: string | null;
|
34
34
|
}>;
|
35
35
|
static update(id: Creator["model"]["id"], { addresses, ...creator }: UpdateCreatorDto): Promise<{
|
36
|
-
name: string;
|
37
36
|
id: string;
|
37
|
+
name: string;
|
38
38
|
icon: string | null;
|
39
39
|
}>;
|
40
40
|
}
|
@@ -18,8 +18,8 @@ export declare abstract class CreatorService {
|
|
18
18
|
creatorId: string | null;
|
19
19
|
}[];
|
20
20
|
} & {
|
21
|
-
name: string;
|
22
21
|
id: string;
|
22
|
+
name: string;
|
23
23
|
icon: string | null;
|
24
24
|
}) | null>;
|
25
25
|
/**
|
@@ -34,8 +34,8 @@ export declare abstract class CreatorService {
|
|
34
34
|
creatorId: string | null;
|
35
35
|
}[];
|
36
36
|
} & {
|
37
|
-
name: string;
|
38
37
|
id: string;
|
38
|
+
name: string;
|
39
39
|
icon: string | null;
|
40
40
|
})[]>;
|
41
41
|
/**
|
@@ -43,8 +43,8 @@ export declare abstract class CreatorService {
|
|
43
43
|
* @param creator {addresses, id, name}
|
44
44
|
*/
|
45
45
|
static create(creator: Creator["model"]): Promise<{
|
46
|
-
name: string;
|
47
46
|
id: string;
|
47
|
+
name: string;
|
48
48
|
icon: string | null;
|
49
49
|
}>;
|
50
50
|
/**
|
@@ -54,8 +54,8 @@ export declare abstract class CreatorService {
|
|
54
54
|
* @param creator data for each field
|
55
55
|
*/
|
56
56
|
static update(id: Creator["model"]["id"], creator: UpdateCreatorDto): Promise<{
|
57
|
-
name: string;
|
58
57
|
id: string;
|
58
|
+
name: string;
|
59
59
|
icon: string | null;
|
60
60
|
}>;
|
61
61
|
}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { AuthorizationHeadersDto, BackOfficeGuard } from "
|
1
|
+
import { AuthorizationHeadersDto, BackOfficeGuard } from "@/guards/BackOffice.guard";
|
2
2
|
import Elysia from "elysia";
|
3
3
|
import { throwOnUnsupportedChainId } from "src/utils/throw";
|
4
4
|
import { DynamicDataSourceIdentifier } from "./dynamicData.model";
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import type { SinglePayloadInputDto } from "
|
1
|
+
import type { SinglePayloadInputDto } from "@/modules/v4/programPayload/programPayload.model";
|
2
2
|
export declare const DynamicDataSourceIdentifier: import("@sinclair/typebox").TObject<{
|
3
3
|
chainId: import("@sinclair/typebox").TNumber;
|
4
4
|
tokenAddress: import("@sinclair/typebox").TString;
|
@@ -1,9 +1,9 @@
|
|
1
|
-
import { HttpError } from "
|
2
|
-
import { campaignsDynamicData } from "
|
3
|
-
import { OpportunityService } from "
|
4
|
-
import bigintToString from "
|
5
|
-
import { executeSimple } from "
|
6
|
-
import { log } from "
|
1
|
+
import { HttpError } from "@/errors";
|
2
|
+
import { campaignsDynamicData } from "@/libs/campaigns/campaignsDynamicData";
|
3
|
+
import { OpportunityService } from "@/modules/v4/opportunity/opportunity.service";
|
4
|
+
import bigintToString from "@/utils/bigintToString";
|
5
|
+
import { executeSimple } from "@/utils/execute";
|
6
|
+
import { log } from "@/utils/logger";
|
7
7
|
import { Campaign, NETWORK_LABELS } from "@sdk";
|
8
8
|
import { Campaign as CampaignEnum } from "@sdk";
|
9
9
|
import { AprService } from "../apr";
|
@@ -126,7 +126,6 @@ export class DynamicDataService {
|
|
126
126
|
campaigns: campaigns,
|
127
127
|
});
|
128
128
|
}
|
129
|
-
// 2. Call updateDynamicData with each entries of the map (process by campaign type)
|
130
129
|
}
|
131
130
|
return dynamicDataArray.flat();
|
132
131
|
}
|
@@ -1,40 +1,40 @@
|
|
1
1
|
export declare const slugToProtocolId: {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
2
|
+
"uniswap-v2": "uniswap-v2";
|
3
|
+
"aave-v3": "aave";
|
4
|
+
"aave-v2": "aave";
|
5
|
+
"aave-static-atokens": "aave";
|
6
|
+
"camelot-v2": "camelot";
|
7
|
+
"meta-morpho": "morpho";
|
8
|
+
"morpho-blue-vaults": "morpho";
|
9
|
+
"balancer-v2": "balancer";
|
10
|
+
"balancer-gauge": "balancer";
|
11
|
+
"aura-lp": "aura";
|
12
|
+
aura: "aura";
|
13
|
+
beefy: "beefy";
|
14
|
+
venus: "venus";
|
15
|
+
"compound-v3": "compound";
|
16
|
+
"curve-gauge": "curve";
|
17
|
+
"euler-v2": "euler";
|
18
|
+
fluid: "fluid";
|
19
|
+
fraxlend: "frax";
|
20
|
+
"frax-ether": "frax";
|
21
|
+
"gearbox-v3": "gearbox";
|
22
|
+
gearbox: "gearbox";
|
23
|
+
moonwell: "moonwell";
|
24
|
+
"pancakeswap-amm-v3": "pancakeswap-v3";
|
25
|
+
"quickswap-dex": "quickswap-uni";
|
26
|
+
"silo-protected": "silo";
|
27
|
+
silo: "silo";
|
28
|
+
"velodrome-v2-staking": "velodrome";
|
29
|
+
zerolend: "zerolend";
|
30
30
|
};
|
31
31
|
export type EnsoSlug = keyof typeof slugToProtocolId;
|
32
32
|
export declare const apiTypes: {
|
33
|
-
|
34
|
-
|
33
|
+
"/v1/protocols": {
|
34
|
+
query: import("@sinclair/typebox").TObject<{
|
35
35
|
slug: import("@sinclair/typebox").TString;
|
36
36
|
}>;
|
37
|
-
|
37
|
+
response: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
|
38
38
|
slug: import("@sinclair/typebox").TString;
|
39
39
|
name: import("@sinclair/typebox").TString;
|
40
40
|
desription: import("@sinclair/typebox").TString;
|
@@ -46,8 +46,8 @@ export declare const apiTypes: {
|
|
46
46
|
}>>;
|
47
47
|
}>>;
|
48
48
|
};
|
49
|
-
|
50
|
-
|
49
|
+
"/v1/tokens": {
|
50
|
+
query: import("@sinclair/typebox").TObject<{
|
51
51
|
protocolSlug: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
52
52
|
primaryAddress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
53
53
|
address: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
@@ -59,7 +59,7 @@ export declare const apiTypes: {
|
|
59
59
|
page: import("@sinclair/typebox").TNumber;
|
60
60
|
inludeMetadata: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
61
61
|
}>;
|
62
|
-
|
62
|
+
response: import("@sinclair/typebox").TObject<{
|
63
63
|
data: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
|
64
64
|
chainId: import("@sinclair/typebox").TNumber;
|
65
65
|
address: import("@sinclair/typebox").TString;
|
@@ -88,8 +88,8 @@ export declare const apiTypes: {
|
|
88
88
|
}>;
|
89
89
|
}>;
|
90
90
|
};
|
91
|
-
|
92
|
-
|
91
|
+
"/v1/shortcuts/quote": {
|
92
|
+
query: import("@sinclair/typebox").TObject<{
|
93
93
|
chainId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
94
94
|
fromAddress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
95
95
|
routingStrategy: import("@sinclair/typebox").TEnum<{
|
@@ -106,15 +106,15 @@ export declare const apiTypes: {
|
|
106
106
|
ignoreAggregators: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
|
107
107
|
ignoreStandards: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
|
108
108
|
}>;
|
109
|
-
|
109
|
+
response: import("@sinclair/typebox").TObject<{
|
110
110
|
gas: import("@sinclair/typebox").TString;
|
111
111
|
amountOut: import("@sinclair/typebox").TObject<{}>;
|
112
112
|
priceImpact: import("@sinclair/typebox").TNumber;
|
113
113
|
feeAmount: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
|
114
114
|
}>;
|
115
115
|
};
|
116
|
-
|
117
|
-
|
116
|
+
"/v1/shortcuts/route": {
|
117
|
+
query: import("@sinclair/typebox").TObject<{
|
118
118
|
chainId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
119
119
|
fromAddress: import("@sinclair/typebox").TString;
|
120
120
|
routingStrategy: import("@sinclair/typebox").TEnum<{
|
@@ -136,7 +136,7 @@ export declare const apiTypes: {
|
|
136
136
|
tokenIn: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
|
137
137
|
tokenOut: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
|
138
138
|
}>;
|
139
|
-
|
139
|
+
response: import("@sinclair/typebox").TObject<{
|
140
140
|
gas: import("@sinclair/typebox").TString;
|
141
141
|
amountOut: import("@sinclair/typebox").TString;
|
142
142
|
priceImpact: import("@sinclair/typebox").TNumber;
|
@@ -1,15 +1,15 @@
|
|
1
|
-
import type { GetInteractionProtocolsQuery, InteractionAction, InteractionTarget, Router } from "
|
2
|
-
import type { ProtocolId } from "
|
1
|
+
import type { GetInteractionProtocolsQuery, InteractionAction, InteractionTarget, Router } from "@/modules/v4/interaction/interaction.model";
|
2
|
+
import type { ProtocolId } from "@/modules/v4/protocol/protocol.model";
|
3
3
|
import { type EnsoApi, type EnsoSlug } from "./enso.model";
|
4
4
|
export declare abstract class EnsoService {
|
5
5
|
#private;
|
6
6
|
static getSlug(protocolId: ProtocolId | string): EnsoSlug | undefined;
|
7
7
|
static getProtocolId(slug: EnsoSlug | string): ProtocolId | undefined;
|
8
8
|
static getCompatibleProtocols(query: GetInteractionProtocolsQuery): Promise<({
|
9
|
+
id: string;
|
9
10
|
name: string;
|
10
11
|
url: string;
|
11
12
|
description: string;
|
12
|
-
id: string;
|
13
13
|
tags: string[];
|
14
14
|
icon: string;
|
15
15
|
} & {
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { ProtocolService } from "
|
2
|
-
import { TokenService } from "
|
1
|
+
import { ProtocolService } from "@/modules/v4/protocol/protocol.service";
|
2
|
+
import { TokenService } from "@/modules/v4/token/token.service";
|
3
3
|
import { slugToProtocolId } from "./enso.model";
|
4
4
|
const ENSO = "https://api.enso.finance/api";
|
5
5
|
export class EnsoService {
|
@@ -26,9 +26,9 @@ export declare const ExplorerController: Elysia<"/explorers", false, {
|
|
26
26
|
};
|
27
27
|
response: {
|
28
28
|
200: {
|
29
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
30
|
-
url: string;
|
31
29
|
id: string;
|
30
|
+
type: import("@db/api").$Enums.ExplorerType;
|
31
|
+
url: string;
|
32
32
|
chainId: number;
|
33
33
|
};
|
34
34
|
};
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { AuthorizationHeadersDto, BackOfficeGuard } from "
|
1
|
+
import { AuthorizationHeadersDto, BackOfficeGuard } from "@/guards/BackOffice.guard";
|
2
2
|
import Elysia from "elysia";
|
3
3
|
import { CreateExplorerDto } from "./explorer.model";
|
4
4
|
import { ExplorerService } from "./explorer.service";
|
@@ -1,5 +1,5 @@
|
|
1
1
|
// ─── Schemas ─────────────────────────────────────────────────────────────────
|
2
|
-
import { ExplorerType } from "
|
2
|
+
import { ExplorerType } from "@db/api";
|
3
3
|
import { t } from "elysia";
|
4
4
|
export const CreateExplorerDto = t.Object({
|
5
5
|
chainId: t.Numeric(),
|
@@ -1,9 +1,9 @@
|
|
1
|
-
import type { ExplorerType } from "
|
1
|
+
import type { ExplorerType } from "@db/api";
|
2
2
|
export declare abstract class ExplorerRepository {
|
3
3
|
static getByChainId(chainId: number): Promise<{
|
4
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
5
|
-
url: string;
|
6
4
|
id: string;
|
5
|
+
type: import("@db/api").$Enums.ExplorerType;
|
6
|
+
url: string;
|
7
7
|
chainId: number;
|
8
8
|
}>;
|
9
9
|
/**
|
@@ -13,9 +13,9 @@ export declare abstract class ExplorerRepository {
|
|
13
13
|
* @param url base url without / suffix
|
14
14
|
*/
|
15
15
|
static create(chainId: number, type: ExplorerType, url: string): Promise<{
|
16
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
17
|
-
url: string;
|
18
16
|
id: string;
|
17
|
+
type: import("@db/api").$Enums.ExplorerType;
|
18
|
+
url: string;
|
19
19
|
chainId: number;
|
20
20
|
}>;
|
21
21
|
}
|
@@ -1,15 +1,15 @@
|
|
1
|
-
import type { ExplorerType } from "
|
1
|
+
import type { ExplorerType } from "@db/api";
|
2
2
|
import type { CreateExplorerDto, Explorer } from "./explorer.model";
|
3
3
|
export declare abstract class ExplorerService {
|
4
4
|
static hashId(type: ExplorerType, chainId: number): string;
|
5
5
|
static getByChainId(chainId: number): Promise<{
|
6
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
7
|
-
url: string;
|
8
6
|
id: string;
|
7
|
+
type: import("@db/api").$Enums.ExplorerType;
|
8
|
+
url: string;
|
9
9
|
chainId: number;
|
10
10
|
}>;
|
11
11
|
static format(explorer: Explorer["raw"]): {
|
12
|
-
type: import("
|
12
|
+
type: import("@db/api").$Enums.ExplorerType;
|
13
13
|
url: string;
|
14
14
|
chainId: number;
|
15
15
|
};
|
@@ -20,9 +20,9 @@ export declare abstract class ExplorerService {
|
|
20
20
|
* @param url base url without / suffix
|
21
21
|
*/
|
22
22
|
static create(data: CreateExplorerDto): Promise<{
|
23
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
24
|
-
url: string;
|
25
23
|
id: string;
|
24
|
+
type: import("@db/api").$Enums.ExplorerType;
|
25
|
+
url: string;
|
26
26
|
chainId: number;
|
27
27
|
}>;
|
28
28
|
}
|
@@ -41,10 +41,10 @@ export declare const InteractionController: Elysia<"/interaction", false, {
|
|
41
41
|
headers: unknown;
|
42
42
|
response: {
|
43
43
|
200: ({
|
44
|
+
id: string;
|
44
45
|
name: string;
|
45
46
|
url: string;
|
46
47
|
description: string;
|
47
|
-
id: string;
|
48
48
|
tags: string[];
|
49
49
|
icon: string;
|
50
50
|
} & {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import type { ProtocolId } from "
|
1
|
+
import type { ProtocolId } from "@/modules/v4/protocol/protocol.model";
|
2
2
|
import type { InteractionQuote } from "./interaction.model";
|
3
3
|
export declare abstract class InteractionService {
|
4
4
|
static routers: import("./interaction.model").Router[];
|
@@ -1,6 +1,6 @@
|
|
1
|
-
import { ChainInteractionService } from "
|
2
|
-
import { EnsoService } from "
|
3
|
-
import { KyberZapService } from "
|
1
|
+
import { ChainInteractionService } from "@/modules/v4/chainInteraction/chainInteraction.service";
|
2
|
+
import { EnsoService } from "@/modules/v4/enso/enso.service";
|
3
|
+
import { KyberZapService } from "@/modules/v4/kyberzap/kyberzap.service";
|
4
4
|
import { ETH_ADDRESS, ETH_ZKSYNC_ADDRESS } from "@sdk";
|
5
5
|
import { decodeFunctionResult, encodeFunctionData, parseAbi } from "viem";
|
6
6
|
export class InteractionService {
|
@@ -1,27 +1,27 @@
|
|
1
1
|
export declare const dexIdToProtocolId: {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
2
|
+
DEX_UNISWAPV3: "uniswap-v3";
|
3
|
+
DEX_UNISWAPV2: "uniswap-v2";
|
4
|
+
DEX_PANCAKESWAPV3: "pancakeswap-v3";
|
5
|
+
DEX_SUSHISWAPV3: "sushiswap-v3";
|
6
|
+
DEX_CURVE: "curve";
|
7
|
+
DEX_SYNCSWAP_V3: "syncswap";
|
8
|
+
DEX_ZKSWAP_V3: "zkswap";
|
9
|
+
DEX_QUICKSWAPV3UNI: "quickswap-uni";
|
10
|
+
DEX_QUICKSWAPV3ALGEBRA: "quickswap-algebra";
|
11
|
+
DEX_THRUSTERV3: "thruster";
|
12
|
+
DEX_CAMELOTV3: "camelot";
|
13
|
+
DEX_BEEFY: "beefy";
|
14
|
+
DEX_KOICL: "koi";
|
15
|
+
DEX_AERODROMECL: "aerodrome";
|
16
|
+
DEX_BALANCER: "balancer";
|
17
17
|
};
|
18
18
|
export declare const chainToKyberLabel: {
|
19
19
|
[chainId: number]: string;
|
20
20
|
};
|
21
21
|
export type KyberZapDexId = keyof typeof dexIdToProtocolId;
|
22
22
|
export declare const apiTypes: {
|
23
|
-
|
24
|
-
|
23
|
+
"/api/v1/in/route": {
|
24
|
+
query: import("@sinclair/typebox").TObject<{
|
25
25
|
dex: import("@sinclair/typebox").TString;
|
26
26
|
"pool.id": import("@sinclair/typebox").TString;
|
27
27
|
"position.tickLower": import("@sinclair/typebox").TString;
|
@@ -32,7 +32,7 @@ export declare const apiTypes: {
|
|
32
32
|
feePcm: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
33
33
|
slippage: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
|
34
34
|
}>;
|
35
|
-
|
35
|
+
response: import("@sinclair/typebox").TObject<{
|
36
36
|
message: import("@sinclair/typebox").TString;
|
37
37
|
data: import("@sinclair/typebox").TObject<{
|
38
38
|
poolDetails: import("@sinclair/typebox").TObject<{}>;
|
@@ -48,16 +48,16 @@ export declare const apiTypes: {
|
|
48
48
|
requestId: import("@sinclair/typebox").TString;
|
49
49
|
}>;
|
50
50
|
};
|
51
|
-
|
52
|
-
|
53
|
-
|
51
|
+
"/api/v1/in/route/build": {
|
52
|
+
query: import("@sinclair/typebox").TObject<{}>;
|
53
|
+
body: import("@sinclair/typebox").TObject<{
|
54
54
|
sender: import("@sinclair/typebox").TString;
|
55
55
|
recipient: import("@sinclair/typebox").TString;
|
56
56
|
route: import("@sinclair/typebox").TString;
|
57
57
|
deadline: import("@sinclair/typebox").TNumber;
|
58
58
|
source: import("@sinclair/typebox").TString;
|
59
59
|
}>;
|
60
|
-
|
60
|
+
response: import("@sinclair/typebox").TObject<{
|
61
61
|
message: import("@sinclair/typebox").TString;
|
62
62
|
data: import("@sinclair/typebox").TObject<{
|
63
63
|
routerAddress: import("@sinclair/typebox").TString;
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import type { ProtocolId } from "
|
1
|
+
import type { ProtocolId } from "@/modules/v4/protocol/protocol.model";
|
2
2
|
import type { InteractionAction, Router } from "../interaction/interaction.model";
|
3
3
|
import { type KyberZapDexId, type ZapAction } from "./kyberzap.model";
|
4
4
|
export declare abstract class KyberZapService {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { TokenService } from "
|
1
|
+
import { TokenService } from "@/modules/v4/token/token.service";
|
2
2
|
import { chainToKyberLabel, dexIdToProtocolId, } from "./kyberzap.model";
|
3
3
|
const KYBERZAP = "https://zap-api.kyberswap.com/";
|
4
4
|
export class KyberZapService {
|