@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
@@ -22,11 +22,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
22
22
|
protocols?: string[] | undefined;
|
23
23
|
mainProtocol?: string | undefined;
|
24
24
|
type: string;
|
25
|
+
status: "NONE" | "PAST" | "LIVE" | "SOON";
|
25
26
|
tokens: {
|
26
27
|
chainId: number;
|
27
28
|
address: string;
|
28
29
|
}[];
|
29
|
-
status: "NONE" | "PAST" | "LIVE" | "SOON";
|
30
30
|
identifier: string;
|
31
31
|
chainId: number;
|
32
32
|
action: "POOL" | "HOLD" | "DROP" | "LEND" | "BORROW" | "LONG" | "SHORT" | "INVALID";
|
@@ -38,14 +38,14 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
38
38
|
};
|
39
39
|
response: {
|
40
40
|
200: {
|
41
|
+
id: string;
|
41
42
|
name: string;
|
42
43
|
type: string;
|
43
|
-
|
44
|
-
status: import("../../../../database/api/.generated").$Enums.Status;
|
44
|
+
status: import("@db/api").$Enums.Status;
|
45
45
|
tags: string[];
|
46
46
|
identifier: string;
|
47
47
|
chainId: number;
|
48
|
-
action: import("
|
48
|
+
action: import("@db/api").$Enums.OpportunityAction;
|
49
49
|
depositUrl: string | null;
|
50
50
|
mainProtocolId: string | null;
|
51
51
|
tvl: number;
|
@@ -80,8 +80,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
80
80
|
action: any;
|
81
81
|
tokens: ({
|
82
82
|
symbol: string;
|
83
|
-
name: string | null;
|
84
83
|
id: string;
|
84
|
+
name: string | null;
|
85
85
|
icon: string;
|
86
86
|
chainId: number;
|
87
87
|
address: string;
|
@@ -107,11 +107,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
107
107
|
body: unknown;
|
108
108
|
params: {};
|
109
109
|
query: {
|
110
|
-
sort?: string | undefined;
|
111
110
|
name?: string | undefined;
|
112
111
|
type?: string | undefined;
|
113
|
-
tokens?: string | undefined;
|
114
112
|
status?: string | undefined;
|
113
|
+
sort?: string | undefined;
|
114
|
+
tokens?: string | undefined;
|
115
115
|
items?: number | undefined;
|
116
116
|
tags?: string | undefined;
|
117
117
|
identifier?: string | undefined;
|
@@ -133,8 +133,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
133
133
|
cumulated: number;
|
134
134
|
timestamp: bigint;
|
135
135
|
breakdowns: {
|
136
|
-
type: import("../../../../database/api/.generated").$Enums.AprType;
|
137
136
|
id: number;
|
137
|
+
type: import("@db/api").$Enums.AprType;
|
138
138
|
identifier: string;
|
139
139
|
value: number;
|
140
140
|
aprRecordId: string;
|
@@ -145,8 +145,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
145
145
|
total: number;
|
146
146
|
timestamp: bigint;
|
147
147
|
breakdowns: {
|
148
|
-
type: import("../../../../database/api/.generated").$Enums.TvlType;
|
149
148
|
id: number;
|
149
|
+
type: import("@db/api").$Enums.TvlType;
|
150
150
|
identifier: string;
|
151
151
|
value: number;
|
152
152
|
tvlRecordId: string;
|
@@ -163,8 +163,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
163
163
|
dailyRewardsRecordId: string;
|
164
164
|
token: {
|
165
165
|
symbol: string;
|
166
|
-
name: string | null;
|
167
166
|
id: string;
|
167
|
+
name: string | null;
|
168
168
|
icon: string;
|
169
169
|
chainId: number;
|
170
170
|
address: string;
|
@@ -181,16 +181,16 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
181
181
|
campaigns: {
|
182
182
|
params: any;
|
183
183
|
chain: {
|
184
|
-
name: string;
|
185
184
|
id: number;
|
185
|
+
name: string;
|
186
186
|
icon: string;
|
187
187
|
};
|
188
188
|
endTimestamp: number;
|
189
189
|
startTimestamp: number;
|
190
190
|
rewardToken: {
|
191
191
|
symbol: string;
|
192
|
-
name: string | null;
|
193
192
|
id: string;
|
193
|
+
name: string | null;
|
194
194
|
icon: string;
|
195
195
|
chainId: number;
|
196
196
|
address: string;
|
@@ -202,16 +202,16 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
202
202
|
price?: number | null | undefined;
|
203
203
|
};
|
204
204
|
distributionChain: {
|
205
|
-
name: string;
|
206
205
|
id: number;
|
206
|
+
name: string;
|
207
207
|
icon: string;
|
208
208
|
} | undefined;
|
209
209
|
campaignStatus: {
|
210
210
|
computedUntil: number;
|
211
211
|
processingStarted: number;
|
212
212
|
error: string;
|
213
|
+
status: import("@db/api").$Enums.RunStatus;
|
213
214
|
details: import("database/api/.generated/runtime/library").JsonValue;
|
214
|
-
status: import("../../../../database/api/.generated").$Enums.RunStatus;
|
215
215
|
campaignId: string;
|
216
216
|
} | undefined;
|
217
217
|
creatorAddress: string;
|
@@ -221,22 +221,22 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
221
221
|
creatorId: string | null;
|
222
222
|
};
|
223
223
|
Opportunity: {
|
224
|
+
id: string;
|
224
225
|
name: string;
|
225
226
|
type: string;
|
226
|
-
|
227
|
-
status: import("../../../../database/api/.generated").$Enums.Status;
|
227
|
+
status: import("@db/api").$Enums.Status;
|
228
228
|
tags: string[];
|
229
229
|
identifier: string;
|
230
230
|
chainId: number;
|
231
|
-
action: import("
|
231
|
+
action: import("@db/api").$Enums.OpportunityAction;
|
232
232
|
depositUrl: string | null;
|
233
233
|
mainProtocolId: string | null;
|
234
234
|
tvl: number;
|
235
235
|
apr: number;
|
236
236
|
dailyRewards: number;
|
237
237
|
};
|
238
|
-
type: string;
|
239
238
|
id: string;
|
239
|
+
type: string;
|
240
240
|
subType: number | null;
|
241
241
|
computeChainId: number;
|
242
242
|
distributionChainId: number;
|
@@ -244,14 +244,14 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
244
244
|
rewardTokenId: string;
|
245
245
|
amount: string;
|
246
246
|
opportunityId: string;
|
247
|
-
manualOverrides: import("
|
247
|
+
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
248
248
|
}[] | undefined;
|
249
249
|
id: string;
|
250
250
|
depositUrl: string | undefined;
|
251
251
|
tokens: ({
|
252
252
|
symbol: string;
|
253
|
-
name: string | null;
|
254
253
|
id: string;
|
254
|
+
name: string | null;
|
255
255
|
icon: string;
|
256
256
|
chainId: number;
|
257
257
|
address: string;
|
@@ -264,31 +264,31 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
264
264
|
})[];
|
265
265
|
chain: {
|
266
266
|
Explorer: {
|
267
|
-
type: import("../../../../database/api/.generated").$Enums.ExplorerType;
|
268
|
-
url: string;
|
269
267
|
id: string;
|
268
|
+
type: import("@db/api").$Enums.ExplorerType;
|
269
|
+
url: string;
|
270
270
|
chainId: number;
|
271
271
|
}[];
|
272
272
|
} & {
|
273
|
-
name: string;
|
274
273
|
id: number;
|
274
|
+
name: string;
|
275
275
|
icon: string;
|
276
276
|
};
|
277
277
|
protocol: {
|
278
|
+
id: string;
|
278
279
|
name: string;
|
279
280
|
url: string;
|
280
281
|
description: string;
|
281
|
-
id: string;
|
282
282
|
tags: string[];
|
283
283
|
icon: string;
|
284
284
|
} | undefined;
|
285
285
|
name: string;
|
286
286
|
type: string;
|
287
|
-
status: import("
|
287
|
+
status: import("@db/api").$Enums.Status;
|
288
288
|
tags: string[];
|
289
289
|
identifier: string;
|
290
290
|
chainId: number;
|
291
|
-
action: import("
|
291
|
+
action: import("@db/api").$Enums.OpportunityAction;
|
292
292
|
tvl: number;
|
293
293
|
dailyRewards: number;
|
294
294
|
}[];
|
@@ -303,11 +303,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
303
303
|
body: unknown;
|
304
304
|
params: {};
|
305
305
|
query: {
|
306
|
-
sort?: string | undefined;
|
307
306
|
name?: string | undefined;
|
308
307
|
type?: string | undefined;
|
309
|
-
tokens?: string | undefined;
|
310
308
|
status?: string | undefined;
|
309
|
+
sort?: string | undefined;
|
310
|
+
tokens?: string | undefined;
|
311
311
|
items?: number | undefined;
|
312
312
|
tags?: string | undefined;
|
313
313
|
identifier?: string | undefined;
|
@@ -343,10 +343,10 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
343
343
|
response: {
|
344
344
|
200: {
|
345
345
|
protocol?: {
|
346
|
+
id: string;
|
346
347
|
name: string;
|
347
348
|
url: string;
|
348
349
|
description: string;
|
349
|
-
id: string;
|
350
350
|
tags: string[];
|
351
351
|
icon: string;
|
352
352
|
} | null | undefined;
|
@@ -355,8 +355,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
355
355
|
timestamp: string | bigint;
|
356
356
|
cumulated: number;
|
357
357
|
breakdowns: {
|
358
|
-
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
359
358
|
id: number;
|
359
|
+
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
360
360
|
identifier: string;
|
361
361
|
value: number;
|
362
362
|
aprRecordId: string;
|
@@ -366,23 +366,24 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
366
366
|
total: number;
|
367
367
|
timestamp: string | bigint;
|
368
368
|
breakdowns: {
|
369
|
-
type: "TOKEN" | "PROTOCOL";
|
370
369
|
id: number;
|
370
|
+
type: "TOKEN" | "PROTOCOL";
|
371
371
|
identifier: string;
|
372
372
|
value: number;
|
373
373
|
tvlRecordId: string;
|
374
374
|
}[];
|
375
375
|
} | undefined;
|
376
376
|
rewardsRecord?: {
|
377
|
-
total: number;
|
378
377
|
id: string;
|
378
|
+
total: number;
|
379
379
|
timestamp: string | bigint;
|
380
380
|
breakdowns: {
|
381
|
+
id: number;
|
381
382
|
token: {
|
382
383
|
price?: number | null | undefined;
|
383
384
|
symbol: string;
|
384
|
-
name: string | null;
|
385
385
|
id: string;
|
386
|
+
name: string | null;
|
386
387
|
icon: string;
|
387
388
|
chainId: number;
|
388
389
|
address: string;
|
@@ -390,20 +391,21 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
390
391
|
verified: boolean;
|
391
392
|
isTest: boolean;
|
392
393
|
};
|
393
|
-
id: number;
|
394
394
|
value: number;
|
395
395
|
campaignId: string;
|
396
396
|
amount: string | bigint;
|
397
397
|
dailyRewardsRecordId: string;
|
398
398
|
}[];
|
399
399
|
} | undefined;
|
400
|
+
id: string;
|
400
401
|
name: string;
|
401
402
|
type: string;
|
403
|
+
status: string;
|
402
404
|
tokens: {
|
403
405
|
price?: number | null | undefined;
|
404
406
|
symbol: string;
|
405
|
-
name: string | null;
|
406
407
|
id: string;
|
408
|
+
name: string | null;
|
407
409
|
icon: string;
|
408
410
|
chainId: number;
|
409
411
|
address: string;
|
@@ -411,13 +413,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
411
413
|
verified: boolean;
|
412
414
|
isTest: boolean;
|
413
415
|
}[];
|
414
|
-
id: string;
|
415
|
-
status: string;
|
416
416
|
tags: string[];
|
417
417
|
identifier: string;
|
418
418
|
chain: {
|
419
|
-
name: string;
|
420
419
|
id: number;
|
420
|
+
name: string;
|
421
421
|
icon: string;
|
422
422
|
};
|
423
423
|
chainId: number;
|
@@ -427,12 +427,12 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
427
427
|
dailyRewards: number;
|
428
428
|
};
|
429
429
|
readonly 404: {
|
430
|
-
message: string;
|
431
430
|
name: string;
|
431
|
+
message: string;
|
432
432
|
};
|
433
433
|
readonly 500: {
|
434
|
-
code: string;
|
435
434
|
info: string;
|
435
|
+
code: string;
|
436
436
|
httpCode: number;
|
437
437
|
};
|
438
438
|
};
|
@@ -471,10 +471,10 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
471
471
|
response: {
|
472
472
|
200: {
|
473
473
|
protocol?: {
|
474
|
+
id: string;
|
474
475
|
name: string;
|
475
476
|
url: string;
|
476
477
|
description: string;
|
477
|
-
id: string;
|
478
478
|
tags: string[];
|
479
479
|
icon: string;
|
480
480
|
} | null | undefined;
|
@@ -483,8 +483,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
483
483
|
timestamp: string | bigint;
|
484
484
|
cumulated: number;
|
485
485
|
breakdowns: {
|
486
|
-
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
487
486
|
id: number;
|
487
|
+
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
488
488
|
identifier: string;
|
489
489
|
value: number;
|
490
490
|
aprRecordId: string;
|
@@ -494,23 +494,24 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
494
494
|
total: number;
|
495
495
|
timestamp: string | bigint;
|
496
496
|
breakdowns: {
|
497
|
-
type: "TOKEN" | "PROTOCOL";
|
498
497
|
id: number;
|
498
|
+
type: "TOKEN" | "PROTOCOL";
|
499
499
|
identifier: string;
|
500
500
|
value: number;
|
501
501
|
tvlRecordId: string;
|
502
502
|
}[];
|
503
503
|
} | undefined;
|
504
504
|
rewardsRecord?: {
|
505
|
-
total: number;
|
506
505
|
id: string;
|
506
|
+
total: number;
|
507
507
|
timestamp: string | bigint;
|
508
508
|
breakdowns: {
|
509
|
+
id: number;
|
509
510
|
token: {
|
510
511
|
price?: number | null | undefined;
|
511
512
|
symbol: string;
|
512
|
-
name: string | null;
|
513
513
|
id: string;
|
514
|
+
name: string | null;
|
514
515
|
icon: string;
|
515
516
|
chainId: number;
|
516
517
|
address: string;
|
@@ -518,20 +519,21 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
518
519
|
verified: boolean;
|
519
520
|
isTest: boolean;
|
520
521
|
};
|
521
|
-
id: number;
|
522
522
|
value: number;
|
523
523
|
campaignId: string;
|
524
524
|
amount: string | bigint;
|
525
525
|
dailyRewardsRecordId: string;
|
526
526
|
}[];
|
527
527
|
} | undefined;
|
528
|
+
id: string;
|
528
529
|
name: string;
|
529
530
|
type: string;
|
531
|
+
status: string;
|
530
532
|
tokens: {
|
531
533
|
price?: number | null | undefined;
|
532
534
|
symbol: string;
|
533
|
-
name: string | null;
|
534
535
|
id: string;
|
536
|
+
name: string | null;
|
535
537
|
icon: string;
|
536
538
|
chainId: number;
|
537
539
|
address: string;
|
@@ -539,13 +541,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
539
541
|
verified: boolean;
|
540
542
|
isTest: boolean;
|
541
543
|
}[];
|
542
|
-
id: string;
|
543
|
-
status: string;
|
544
544
|
tags: string[];
|
545
545
|
identifier: string;
|
546
546
|
chain: {
|
547
|
-
name: string;
|
548
547
|
id: number;
|
548
|
+
name: string;
|
549
549
|
icon: string;
|
550
550
|
};
|
551
551
|
chainId: number;
|
@@ -568,17 +568,17 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
568
568
|
processingStarted: string | number;
|
569
569
|
} | undefined;
|
570
570
|
distributionChain?: {
|
571
|
-
name: string;
|
572
571
|
id: number;
|
572
|
+
name: string;
|
573
573
|
icon: string;
|
574
574
|
} | undefined;
|
575
|
-
type: string;
|
576
575
|
id: string;
|
576
|
+
type: string;
|
577
577
|
params: any;
|
578
578
|
subType: number | null;
|
579
579
|
chain: {
|
580
|
-
name: string;
|
581
580
|
id: number;
|
581
|
+
name: string;
|
582
582
|
icon: string;
|
583
583
|
};
|
584
584
|
startTimestamp: string | number;
|
@@ -593,8 +593,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
593
593
|
rewardToken: {
|
594
594
|
price?: number | null | undefined;
|
595
595
|
symbol: string;
|
596
|
-
name: string | null;
|
597
596
|
id: string;
|
597
|
+
name: string | null;
|
598
598
|
icon: string;
|
599
599
|
chainId: number;
|
600
600
|
address: string;
|
@@ -605,12 +605,12 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
605
605
|
}[];
|
606
606
|
}[];
|
607
607
|
readonly 404: {
|
608
|
-
message: string;
|
609
608
|
name: string;
|
609
|
+
message: string;
|
610
610
|
};
|
611
611
|
readonly 500: {
|
612
|
-
code: string;
|
613
612
|
info: string;
|
613
|
+
code: string;
|
614
614
|
httpCode: number;
|
615
615
|
};
|
616
616
|
};
|
@@ -633,10 +633,10 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
633
633
|
response: {
|
634
634
|
200: {
|
635
635
|
protocol?: {
|
636
|
+
id: string;
|
636
637
|
name: string;
|
637
638
|
url: string;
|
638
639
|
description: string;
|
639
|
-
id: string;
|
640
640
|
tags: string[];
|
641
641
|
icon: string;
|
642
642
|
} | null | undefined;
|
@@ -645,8 +645,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
645
645
|
timestamp: string | bigint;
|
646
646
|
cumulated: number;
|
647
647
|
breakdowns: {
|
648
|
-
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
649
648
|
id: number;
|
649
|
+
type: "CAMPAIGN" | "TOKEN" | "PROTOCOL";
|
650
650
|
identifier: string;
|
651
651
|
value: number;
|
652
652
|
aprRecordId: string;
|
@@ -656,23 +656,24 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
656
656
|
total: number;
|
657
657
|
timestamp: string | bigint;
|
658
658
|
breakdowns: {
|
659
|
-
type: "TOKEN" | "PROTOCOL";
|
660
659
|
id: number;
|
660
|
+
type: "TOKEN" | "PROTOCOL";
|
661
661
|
identifier: string;
|
662
662
|
value: number;
|
663
663
|
tvlRecordId: string;
|
664
664
|
}[];
|
665
665
|
} | undefined;
|
666
666
|
rewardsRecord?: {
|
667
|
-
total: number;
|
668
667
|
id: string;
|
668
|
+
total: number;
|
669
669
|
timestamp: string | bigint;
|
670
670
|
breakdowns: {
|
671
|
+
id: number;
|
671
672
|
token: {
|
672
673
|
price?: number | null | undefined;
|
673
674
|
symbol: string;
|
674
|
-
name: string | null;
|
675
675
|
id: string;
|
676
|
+
name: string | null;
|
676
677
|
icon: string;
|
677
678
|
chainId: number;
|
678
679
|
address: string;
|
@@ -680,20 +681,21 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
680
681
|
verified: boolean;
|
681
682
|
isTest: boolean;
|
682
683
|
};
|
683
|
-
id: number;
|
684
684
|
value: number;
|
685
685
|
campaignId: string;
|
686
686
|
amount: string | bigint;
|
687
687
|
dailyRewardsRecordId: string;
|
688
688
|
}[];
|
689
689
|
} | undefined;
|
690
|
+
id: string;
|
690
691
|
name: string;
|
691
692
|
type: string;
|
693
|
+
status: string;
|
692
694
|
tokens: {
|
693
695
|
price?: number | null | undefined;
|
694
696
|
symbol: string;
|
695
|
-
name: string | null;
|
696
697
|
id: string;
|
698
|
+
name: string | null;
|
697
699
|
icon: string;
|
698
700
|
chainId: number;
|
699
701
|
address: string;
|
@@ -701,13 +703,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
701
703
|
verified: boolean;
|
702
704
|
isTest: boolean;
|
703
705
|
}[];
|
704
|
-
id: string;
|
705
|
-
status: string;
|
706
706
|
tags: string[];
|
707
707
|
identifier: string;
|
708
708
|
chain: {
|
709
|
-
name: string;
|
710
709
|
id: number;
|
710
|
+
name: string;
|
711
711
|
icon: string;
|
712
712
|
};
|
713
713
|
chainId: number;
|
@@ -730,17 +730,17 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
730
730
|
processingStarted: string | number;
|
731
731
|
} | undefined;
|
732
732
|
distributionChain?: {
|
733
|
-
name: string;
|
734
733
|
id: number;
|
734
|
+
name: string;
|
735
735
|
icon: string;
|
736
736
|
} | undefined;
|
737
|
-
type: string;
|
738
737
|
id: string;
|
738
|
+
type: string;
|
739
739
|
params: any;
|
740
740
|
subType: number | null;
|
741
741
|
chain: {
|
742
|
-
name: string;
|
743
742
|
id: number;
|
743
|
+
name: string;
|
744
744
|
icon: string;
|
745
745
|
};
|
746
746
|
startTimestamp: string | number;
|
@@ -755,8 +755,8 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
755
755
|
rewardToken: {
|
756
756
|
price?: number | null | undefined;
|
757
757
|
symbol: string;
|
758
|
-
name: string | null;
|
759
758
|
id: string;
|
759
|
+
name: string | null;
|
760
760
|
icon: string;
|
761
761
|
chainId: number;
|
762
762
|
address: string;
|
@@ -767,12 +767,12 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
767
767
|
}[];
|
768
768
|
};
|
769
769
|
readonly 404: {
|
770
|
-
message: string;
|
771
770
|
name: string;
|
771
|
+
message: string;
|
772
772
|
};
|
773
773
|
readonly 500: {
|
774
|
-
code: string;
|
775
774
|
info: string;
|
775
|
+
code: string;
|
776
776
|
httpCode: number;
|
777
777
|
};
|
778
778
|
};
|
@@ -790,11 +790,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
790
790
|
field: never;
|
791
791
|
};
|
792
792
|
query: {
|
793
|
-
sort?: string | undefined;
|
794
793
|
name?: string | undefined;
|
795
794
|
type?: string | undefined;
|
796
|
-
tokens?: string | undefined;
|
797
795
|
status?: string | undefined;
|
796
|
+
sort?: string | undefined;
|
797
|
+
tokens?: string | undefined;
|
798
798
|
items?: number | undefined;
|
799
799
|
tags?: string | undefined;
|
800
800
|
identifier?: string | undefined;
|
@@ -829,11 +829,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
829
829
|
field: never;
|
830
830
|
};
|
831
831
|
query: {
|
832
|
-
sort?: string | undefined;
|
833
832
|
name?: string | undefined;
|
834
833
|
type?: string | undefined;
|
835
|
-
tokens?: string | undefined;
|
836
834
|
status?: string | undefined;
|
835
|
+
sort?: string | undefined;
|
836
|
+
tokens?: string | undefined;
|
837
837
|
items?: number | undefined;
|
838
838
|
tags?: string | undefined;
|
839
839
|
identifier?: string | undefined;
|
@@ -869,11 +869,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
869
869
|
field: never;
|
870
870
|
};
|
871
871
|
query: {
|
872
|
-
sort?: string | undefined;
|
873
872
|
name?: string | undefined;
|
874
873
|
type?: string | undefined;
|
875
|
-
tokens?: string | undefined;
|
876
874
|
status?: string | undefined;
|
875
|
+
sort?: string | undefined;
|
876
|
+
tokens?: string | undefined;
|
877
877
|
items?: number | undefined;
|
878
878
|
tags?: string | undefined;
|
879
879
|
identifier?: string | undefined;
|
@@ -916,14 +916,14 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
916
916
|
};
|
917
917
|
response: {
|
918
918
|
200: {
|
919
|
+
id: string;
|
919
920
|
name: string;
|
920
921
|
type: string;
|
921
|
-
|
922
|
-
status: import("../../../../database/api/.generated").$Enums.Status;
|
922
|
+
status: import("@db/api").$Enums.Status;
|
923
923
|
tags: string[];
|
924
924
|
identifier: string;
|
925
925
|
chainId: number;
|
926
|
-
action: import("
|
926
|
+
action: import("@db/api").$Enums.OpportunityAction;
|
927
927
|
depositUrl: string | null;
|
928
928
|
mainProtocolId: string | null;
|
929
929
|
tvl: number;
|
@@ -1,6 +1,6 @@
|
|
1
|
-
import { HttpErrorDto, NotFoundError, NotFoundErrorDto } from "
|
2
|
-
import { BackOfficeGuard } from "
|
3
|
-
import { AuthorizationHeadersDto, TokenAuthGuard } from "
|
1
|
+
import { HttpErrorDto, NotFoundError, NotFoundErrorDto } from "@/errors";
|
2
|
+
import { BackOfficeGuard } from "@/guards/BackOffice.guard";
|
3
|
+
import { AuthorizationHeadersDto, TokenAuthGuard } from "@/guards/TokenAuth.guard";
|
4
4
|
import Elysia, { t } from "elysia";
|
5
5
|
import { GetCampaignQueryDto } from "../campaign";
|
6
6
|
import { CreateOpportunityDto, GetOpportunitiesQueryDto, GetOpportunityQueryDto, OpportunityAggregateFieldDto, OpportunityIdDto, OpportunityResourceDto, OpportunityUniqueDto, OpportunityUniqueUpdateDto, OpportunityWithCampaignsResourceDto, UpdateOpportunityDto, } from "./opportunity.model";
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import { kebabToPascalCase } from "
|
2
|
-
import { log } from "
|
1
|
+
import { kebabToPascalCase } from "@/utils/camelToKebabCase";
|
2
|
+
import { log } from "@/utils/logger";
|
3
3
|
import { Campaign as CampaignEnum, EAprBreakdownType, opportunityActions, } from "@sdk";
|
4
4
|
import moment from "moment";
|
5
5
|
import { CacheService } from "../cache";
|