@merkl/api 0.19.11 → 0.19.13
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 +3 -10
- package/dist/database/api/seeder/resources/protocol.js +3 -10
- package/dist/src/eden/index.d.ts +460 -456
- package/dist/src/index.d.ts +168 -160
- package/dist/src/modules/v4/campaign/campaign.controller.d.ts +199 -158
- package/dist/src/modules/v4/campaign/campaign.controller.js +28 -32
- package/dist/src/modules/v4/campaign/campaign.model.d.ts +3 -1
- package/dist/src/modules/v4/campaign/campaign.model.js +2 -1
- package/dist/src/modules/v4/campaign/campaign.repository.js +1 -1
- package/dist/src/modules/v4/campaign/campaign.service.d.ts +5 -10
- package/dist/src/modules/v4/campaign/campaign.service.js +3 -2
- package/dist/src/modules/v4/enso/enso.model.d.ts +2 -2
- package/dist/src/modules/v4/enso/enso.model.js +2 -2
- package/dist/src/modules/v4/kyberzap/kyberzap.model.d.ts +4 -4
- package/dist/src/modules/v4/kyberzap/kyberzap.model.js +4 -4
- package/dist/src/modules/v4/opportunity/opportunity.controller.d.ts +4 -3
- package/dist/src/modules/v4/opportunity/opportunity.model.d.ts +2 -1
- package/dist/src/modules/v4/opportunity/opportunity.service.d.ts +5 -6
- package/dist/src/modules/v4/opportunity/opportunity.service.js +6 -9
- package/dist/src/modules/v4/protocol/protocol.model.d.ts +1 -1
- package/dist/src/modules/v4/protocol/protocol.model.js +5 -8
- package/dist/src/modules/v4/protocol/protocol.service.js +0 -17
- package/dist/src/modules/v4/router.d.ts +168 -160
- package/dist/tsconfig.package.tsbuildinfo +1 -1
- package/package.json +1 -1
@@ -228,6 +228,7 @@ export declare abstract class CampaignService {
|
|
228
228
|
address: string;
|
229
229
|
creatorId: string | null;
|
230
230
|
};
|
231
|
+
createdAt: string;
|
231
232
|
Opportunity: {
|
232
233
|
id: string;
|
233
234
|
name: string;
|
@@ -252,8 +253,6 @@ export declare abstract class CampaignService {
|
|
252
253
|
rewardTokenId: string;
|
253
254
|
amount: string;
|
254
255
|
opportunityId: string;
|
255
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
256
|
-
createdAt: Date;
|
257
256
|
}[]>;
|
258
257
|
static findAndGroupByChains(query: GetCampaignQueryModel): Promise<Map<number, {
|
259
258
|
params: any;
|
@@ -298,6 +297,7 @@ export declare abstract class CampaignService {
|
|
298
297
|
address: string;
|
299
298
|
creatorId: string | null;
|
300
299
|
};
|
300
|
+
createdAt: string;
|
301
301
|
Opportunity: {
|
302
302
|
id: string;
|
303
303
|
name: string;
|
@@ -322,8 +322,6 @@ export declare abstract class CampaignService {
|
|
322
322
|
rewardTokenId: string;
|
323
323
|
amount: string;
|
324
324
|
opportunityId: string;
|
325
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
326
|
-
createdAt: Date;
|
327
325
|
}[]>>;
|
328
326
|
static countByChains(query: GetCampaignQueryModel): Promise<Record<string, number>>;
|
329
327
|
static findAndGroupByType(query: GetCampaignQueryModel): Promise<Map<string, {
|
@@ -369,6 +367,7 @@ export declare abstract class CampaignService {
|
|
369
367
|
address: string;
|
370
368
|
creatorId: string | null;
|
371
369
|
};
|
370
|
+
createdAt: string;
|
372
371
|
Opportunity: {
|
373
372
|
id: string;
|
374
373
|
name: string;
|
@@ -393,8 +392,6 @@ export declare abstract class CampaignService {
|
|
393
392
|
rewardTokenId: string;
|
394
393
|
amount: string;
|
395
394
|
opportunityId: string;
|
396
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
397
|
-
createdAt: Date;
|
398
395
|
}[]>>;
|
399
396
|
static countByType(query: GetCampaignQueryModel): Promise<Record<string, number>>;
|
400
397
|
static findAndGroupByProtocol(query: GetCampaignQueryModel): Promise<Map<string | null, {
|
@@ -440,6 +437,7 @@ export declare abstract class CampaignService {
|
|
440
437
|
address: string;
|
441
438
|
creatorId: string | null;
|
442
439
|
};
|
440
|
+
createdAt: string;
|
443
441
|
Opportunity: {
|
444
442
|
id: string;
|
445
443
|
name: string;
|
@@ -464,8 +462,6 @@ export declare abstract class CampaignService {
|
|
464
462
|
rewardTokenId: string;
|
465
463
|
amount: string;
|
466
464
|
opportunityId: string;
|
467
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
468
|
-
createdAt: Date;
|
469
465
|
}[]>>;
|
470
466
|
static countByProtocol(query: GetCampaignQueryModel): Promise<Record<string, number>>;
|
471
467
|
static countBy<T>(campaignsMap: Map<T, ReturnType<(typeof CampaignService)["format"]>[]>): Record<string, number>;
|
@@ -694,6 +690,7 @@ export declare abstract class CampaignService {
|
|
694
690
|
address: string;
|
695
691
|
creatorId: string | null;
|
696
692
|
};
|
693
|
+
createdAt: string;
|
697
694
|
Opportunity: {
|
698
695
|
id: string;
|
699
696
|
name: string;
|
@@ -718,8 +715,6 @@ export declare abstract class CampaignService {
|
|
718
715
|
rewardTokenId: string;
|
719
716
|
amount: string;
|
720
717
|
opportunityId: string;
|
721
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
722
|
-
createdAt: Date;
|
723
718
|
};
|
724
719
|
static formatAsCampaignParameters<C extends CampaignEnum>(campaign: CampaignWithParams): CampaignParameters<C>;
|
725
720
|
/**
|
@@ -130,7 +130,7 @@ export class CampaignService {
|
|
130
130
|
return Map.groupBy(await CampaignService.findMany(query), campaign => campaign.chain.id);
|
131
131
|
}
|
132
132
|
static async countByChains(query) {
|
133
|
-
return CampaignService.countBy(await CampaignService.findAndGroupByChains(query));
|
133
|
+
return CampaignService.countBy(await CampaignService.findAndGroupByChains({ ...query, items: 0 }));
|
134
134
|
}
|
135
135
|
static async findAndGroupByType(query) {
|
136
136
|
return Map.groupBy(await CampaignService.findMany(query), campaign => campaign.type);
|
@@ -266,7 +266,7 @@ export class CampaignService {
|
|
266
266
|
* TODO: remove CampaignService function in favor of prisma client extensions
|
267
267
|
*/
|
268
268
|
static format(campaign) {
|
269
|
-
const { DistributionChain, ComputeChain, Creator, RewardToken, params, CampaignStatus, ...c } = campaign;
|
269
|
+
const { DistributionChain, ComputeChain, Creator, RewardToken, params, CampaignStatus, createdAt, manualOverrides: _, ...c } = campaign;
|
270
270
|
return {
|
271
271
|
...c,
|
272
272
|
params: params,
|
@@ -279,6 +279,7 @@ export class CampaignService {
|
|
279
279
|
campaignStatus: CampaignStatus?.[0] ? StatusService.format(CampaignStatus?.[0]) : undefined,
|
280
280
|
creatorAddress: Creator.address,
|
281
281
|
creator: Creator,
|
282
|
+
createdAt: createdAt.toISOString(),
|
282
283
|
};
|
283
284
|
}
|
284
285
|
static formatAsCampaignParameters(campaign) {
|
@@ -21,8 +21,8 @@ export declare const slugToProtocolId: {
|
|
21
21
|
"gearbox-v3": "gearbox";
|
22
22
|
gearbox: "gearbox";
|
23
23
|
moonwell: "moonwell";
|
24
|
-
"pancakeswap-amm-v3": "pancakeswap
|
25
|
-
"quickswap-dex": "quickswap
|
24
|
+
"pancakeswap-amm-v3": "pancakeswap";
|
25
|
+
"quickswap-dex": "quickswap";
|
26
26
|
"silo-protected": "silo";
|
27
27
|
silo: "silo";
|
28
28
|
"velodrome-v2-staking": "velodrome";
|
@@ -22,8 +22,8 @@ export const slugToProtocolId = {
|
|
22
22
|
"gearbox-v3": "gearbox",
|
23
23
|
gearbox: "gearbox",
|
24
24
|
moonwell: "moonwell",
|
25
|
-
"pancakeswap-amm-v3": "pancakeswap
|
26
|
-
"quickswap-dex": "quickswap
|
25
|
+
"pancakeswap-amm-v3": "pancakeswap",
|
26
|
+
"quickswap-dex": "quickswap",
|
27
27
|
"silo-protected": "silo",
|
28
28
|
silo: "silo",
|
29
29
|
"velodrome-v2-staking": "velodrome",
|
@@ -1,13 +1,13 @@
|
|
1
1
|
export declare const dexIdToProtocolId: {
|
2
2
|
DEX_UNISWAPV3: "uniswap";
|
3
3
|
DEX_UNISWAPV2: "uniswap";
|
4
|
-
DEX_PANCAKESWAPV3: "pancakeswap
|
5
|
-
DEX_SUSHISWAPV3: "sushiswap
|
4
|
+
DEX_PANCAKESWAPV3: "pancakeswap";
|
5
|
+
DEX_SUSHISWAPV3: "sushiswap";
|
6
6
|
DEX_CURVE: "curve";
|
7
7
|
DEX_SYNCSWAP_V3: "syncswap";
|
8
8
|
DEX_ZKSWAP_V3: "zkswap";
|
9
|
-
DEX_QUICKSWAPV3UNI: "quickswap
|
10
|
-
DEX_QUICKSWAPV3ALGEBRA: "quickswap
|
9
|
+
DEX_QUICKSWAPV3UNI: "quickswap";
|
10
|
+
DEX_QUICKSWAPV3ALGEBRA: "quickswap";
|
11
11
|
DEX_THRUSTERV3: "thruster";
|
12
12
|
DEX_CAMELOTV3: "camelot";
|
13
13
|
DEX_BEEFY: "beefy";
|
@@ -3,14 +3,14 @@ import { t } from "elysia";
|
|
3
3
|
export const dexIdToProtocolId = {
|
4
4
|
DEX_UNISWAPV3: "uniswap",
|
5
5
|
DEX_UNISWAPV2: "uniswap",
|
6
|
-
DEX_PANCAKESWAPV3: "pancakeswap
|
7
|
-
DEX_SUSHISWAPV3: "sushiswap
|
6
|
+
DEX_PANCAKESWAPV3: "pancakeswap",
|
7
|
+
DEX_SUSHISWAPV3: "sushiswap",
|
8
8
|
DEX_CURVE: "curve",
|
9
9
|
DEX_SYNCSWAP_V3: "syncswap",
|
10
10
|
// DEX_SYNCSWAP_V1_V2: "syncswap",
|
11
11
|
DEX_ZKSWAP_V3: "zkswap",
|
12
|
-
DEX_QUICKSWAPV3UNI: "quickswap
|
13
|
-
DEX_QUICKSWAPV3ALGEBRA: "quickswap
|
12
|
+
DEX_QUICKSWAPV3UNI: "quickswap",
|
13
|
+
DEX_QUICKSWAPV3ALGEBRA: "quickswap",
|
14
14
|
DEX_THRUSTERV3: "thruster",
|
15
15
|
DEX_CAMELOTV3: "camelot",
|
16
16
|
DEX_BEEFY: "beefy",
|
@@ -225,6 +225,7 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
225
225
|
address: string;
|
226
226
|
creatorId: string | null;
|
227
227
|
};
|
228
|
+
createdAt: string;
|
228
229
|
Opportunity: {
|
229
230
|
id: string;
|
230
231
|
name: string;
|
@@ -249,8 +250,6 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
249
250
|
rewardTokenId: string;
|
250
251
|
amount: string;
|
251
252
|
opportunityId: string;
|
252
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
253
|
-
createdAt: Date;
|
254
253
|
}[] | undefined;
|
255
254
|
id: string;
|
256
255
|
depositUrl: string | undefined;
|
@@ -466,11 +465,11 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
466
465
|
point?: boolean | undefined;
|
467
466
|
tokenAddress?: string | undefined;
|
468
467
|
test?: boolean | undefined;
|
469
|
-
createdAfter?: number | undefined;
|
470
468
|
creatorTag?: string | undefined;
|
471
469
|
distributionChainIds?: number[] | undefined;
|
472
470
|
tokenSymbol?: string | undefined;
|
473
471
|
withOpportunity?: boolean | undefined;
|
472
|
+
createdAfter?: Date | null | undefined;
|
474
473
|
};
|
475
474
|
headers: unknown;
|
476
475
|
response: {
|
@@ -595,6 +594,7 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
595
594
|
startTimestamp: string | number;
|
596
595
|
endTimestamp: string | number;
|
597
596
|
creatorAddress: string;
|
597
|
+
createdAt: string;
|
598
598
|
rewardToken: {
|
599
599
|
price?: number | null | undefined;
|
600
600
|
symbol: string;
|
@@ -758,6 +758,7 @@ export declare const OpportunityController: Elysia<"/opportunities", false, {
|
|
758
758
|
startTimestamp: string | number;
|
759
759
|
endTimestamp: string | number;
|
760
760
|
creatorAddress: string;
|
761
|
+
createdAt: string;
|
761
762
|
rewardToken: {
|
762
763
|
price?: number | null | undefined;
|
763
764
|
symbol: string;
|
@@ -21,7 +21,7 @@ export type Opportunity = Resource<"Opportunity", "mainProtocolId", {
|
|
21
21
|
aprRecord?: AprRecord["model"];
|
22
22
|
tvlRecord?: TvlRecord["model"];
|
23
23
|
rewardsRecord?: DailyRewardsRecord["model"];
|
24
|
-
campaigns?: Campaign["model"][];
|
24
|
+
campaigns?: Omit<Campaign["model"], "manualOverrides">[];
|
25
25
|
}>;
|
26
26
|
export type LightOpportunityFromDB = Omit<Awaited<ReturnType<typeof OpportunityRepository.findUniqueOrThrow>>, "AprRecords" | "TvlRecords" | "DailyRewardsRecords" | "Campaigns">;
|
27
27
|
export type OpportunityUnique = {
|
@@ -261,6 +261,7 @@ export declare const OpportunityWithCampaignsResourceDto: import("@sinclair/type
|
|
261
261
|
error: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
262
262
|
details: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TAny>;
|
263
263
|
}>>;
|
264
|
+
createdAt: import("@sinclair/typebox").TString;
|
264
265
|
}>>;
|
265
266
|
}>;
|
266
267
|
export declare const OpportunityUniqueDto: import("@sinclair/typebox").TObject<{
|
@@ -262,6 +262,7 @@ export declare abstract class OpportunityService {
|
|
262
262
|
startTimestamp: string | number;
|
263
263
|
endTimestamp: string | number;
|
264
264
|
creatorAddress: string;
|
265
|
+
createdAt: string;
|
265
266
|
rewardToken: {
|
266
267
|
price?: number | null | undefined;
|
267
268
|
symbol: string;
|
@@ -397,6 +398,7 @@ export declare abstract class OpportunityService {
|
|
397
398
|
startTimestamp: string | number;
|
398
399
|
endTimestamp: string | number;
|
399
400
|
creatorAddress: string;
|
401
|
+
createdAt: string;
|
400
402
|
rewardToken: {
|
401
403
|
price?: number | null | undefined;
|
402
404
|
symbol: string;
|
@@ -512,6 +514,7 @@ export declare abstract class OpportunityService {
|
|
512
514
|
address: string;
|
513
515
|
creatorId: string | null;
|
514
516
|
};
|
517
|
+
createdAt: string;
|
515
518
|
Opportunity: {
|
516
519
|
id: string;
|
517
520
|
name: string;
|
@@ -536,8 +539,6 @@ export declare abstract class OpportunityService {
|
|
536
539
|
rewardTokenId: string;
|
537
540
|
amount: string;
|
538
541
|
opportunityId: string;
|
539
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
540
|
-
createdAt: Date;
|
541
542
|
}[] | undefined;
|
542
543
|
id: string;
|
543
544
|
depositUrl: string | undefined;
|
@@ -681,6 +682,7 @@ export declare abstract class OpportunityService {
|
|
681
682
|
address: string;
|
682
683
|
creatorId: string | null;
|
683
684
|
};
|
685
|
+
createdAt: string;
|
684
686
|
Opportunity: {
|
685
687
|
id: string;
|
686
688
|
name: string;
|
@@ -705,8 +707,6 @@ export declare abstract class OpportunityService {
|
|
705
707
|
rewardTokenId: string;
|
706
708
|
amount: string;
|
707
709
|
opportunityId: string;
|
708
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
709
|
-
createdAt: Date;
|
710
710
|
}[] | undefined;
|
711
711
|
id: string;
|
712
712
|
depositUrl: string | undefined;
|
@@ -846,6 +846,7 @@ export declare abstract class OpportunityService {
|
|
846
846
|
address: string;
|
847
847
|
creatorId: string | null;
|
848
848
|
};
|
849
|
+
createdAt: string;
|
849
850
|
Opportunity: {
|
850
851
|
id: string;
|
851
852
|
name: string;
|
@@ -870,8 +871,6 @@ export declare abstract class OpportunityService {
|
|
870
871
|
rewardTokenId: string;
|
871
872
|
amount: string;
|
872
873
|
opportunityId: string;
|
873
|
-
manualOverrides: import("@db/api").$Enums.CampaignManualOverride[];
|
874
|
-
createdAt: Date;
|
875
874
|
}[] | undefined;
|
876
875
|
id: string;
|
877
876
|
depositUrl: string | undefined;
|
@@ -7,7 +7,6 @@ import { TokenService } from "@/modules/v4/token/token.service";
|
|
7
7
|
import { UserService } from "@/modules/v4/user/user.service";
|
8
8
|
import { log } from "@/utils/logger";
|
9
9
|
import { Prisma, Status } from "@db/api";
|
10
|
-
import { record } from "@elysiajs/opentelemetry";
|
11
10
|
import { Campaign as CampaignEnum } from "@sdk";
|
12
11
|
import moment from "moment";
|
13
12
|
import { metadataBuilderFactory } from "../../../engine/opportunityMetadata/factory";
|
@@ -218,14 +217,12 @@ export class OpportunityService {
|
|
218
217
|
return await OpportunityRepository.countMany(query);
|
219
218
|
}
|
220
219
|
static async findLiveWithCampaigns(chainId, take) {
|
221
|
-
return
|
222
|
-
|
223
|
-
|
224
|
-
return
|
225
|
-
|
226
|
-
|
227
|
-
}, chainId);
|
228
|
-
});
|
220
|
+
return await CacheService.wrap(TTLPresets.MIN_10, async (chainId) => {
|
221
|
+
const opportunities = await OpportunityRepository.findLiveWithCampaigns(chainId, take);
|
222
|
+
return opportunities.map(o => {
|
223
|
+
return OpportunityService.formatResponse(o);
|
224
|
+
});
|
225
|
+
}, chainId);
|
229
226
|
}
|
230
227
|
static async getAllIds() {
|
231
228
|
return await OpportunityRepository.getAllIdsForDynamicOpp();
|
@@ -9,7 +9,7 @@ export type Protocol = Resource<"Protocol", undefined, {
|
|
9
9
|
numberOfLiveCampaigns?: number;
|
10
10
|
opportunityLiveTags?: string[];
|
11
11
|
}>;
|
12
|
-
declare const protocolTypes: readonly ["uniswap", "ambient", "arthswap", "baseswap", "camelot", "crust", "fenix", "horiza", "izumi", "kim", "pancakeswap
|
12
|
+
declare const protocolTypes: readonly ["uniswap", "ambient", "arthswap", "baseswap", "camelot", "crust", "fenix", "horiza", "izumi", "kim", "pancakeswap", "quickswap", "ramses", "retro", "stryke", "sushiswap", "swapr", "thruster", "voltage", "zero", "koi", "supswap", "zkswap", "thirdtrade", "velodrome", "aerodrome", "balancer", "curve", "cross_curve", "curveNPool", "aura", "akron", "beefy", "dragonswap", "poolside", "koi", "syncswap", "neptune", "zkSwapThreePool", "syncswap", "rfx", "radiant", "aave", "euler", "gearbox", "compound", "sturdy", "frax", "ionic", "moonwell", "fluid", "silo", "morpho", "coumpound", "dolomite", "badger", "ajna", "layerbank", "ion", "venus", "woofi", "reactor_fusion", "eigenlayer", "vest", "zerolend", "hyperdrive", "gamma", "oku", "hourglass", "veda", "kyo", "sonex", "quickswap-algebra", "velodrome"];
|
13
13
|
export type ProtocolId = (typeof protocolTypes)[number];
|
14
14
|
export declare const ProtocolResourceDto: import("@sinclair/typebox").TObject<{
|
15
15
|
id: import("@sinclair/typebox").TString;
|
@@ -11,21 +11,18 @@ const protocolTypes = [
|
|
11
11
|
"horiza",
|
12
12
|
"izumi",
|
13
13
|
"kim",
|
14
|
-
"pancakeswap
|
15
|
-
"quickswap
|
16
|
-
"quickswap-uni",
|
14
|
+
"pancakeswap",
|
15
|
+
"quickswap",
|
17
16
|
"ramses",
|
18
17
|
"retro",
|
19
18
|
"stryke",
|
20
|
-
"
|
21
|
-
"stryke-sushi",
|
22
|
-
"sushiswap-v3",
|
19
|
+
"sushiswap",
|
23
20
|
"swapr",
|
24
21
|
"thruster",
|
25
22
|
"voltage",
|
26
23
|
"zero",
|
27
24
|
"koi",
|
28
|
-
"supswap
|
25
|
+
"supswap",
|
29
26
|
"zkswap",
|
30
27
|
"thirdtrade",
|
31
28
|
// ─── LP DEX ──────────────────────────────────────────────────────────
|
@@ -41,7 +38,7 @@ const protocolTypes = [
|
|
41
38
|
"dragonswap",
|
42
39
|
"poolside",
|
43
40
|
"koi",
|
44
|
-
"syncswap
|
41
|
+
"syncswap",
|
45
42
|
"neptune",
|
46
43
|
"zkSwapThreePool",
|
47
44
|
"syncswap",
|
@@ -1,27 +1,10 @@
|
|
1
1
|
import { ChainService } from "@/modules/v4/chain/chain.service";
|
2
2
|
import { TokenService } from "@/modules/v4/token/token.service";
|
3
3
|
import { log } from "@/utils/logger";
|
4
|
-
import { apiDbClient } from "@db";
|
5
4
|
import { ProtocolRepository } from "./protocol.repository";
|
6
5
|
// ─── Protocols Services ──────────────────────────────────────────────────────
|
7
6
|
export class ProtocolService {
|
8
7
|
static async findMany(query) {
|
9
|
-
await apiDbClient.opportunity.updateMany({
|
10
|
-
where: {
|
11
|
-
mainProtocolId: "uniswapv4",
|
12
|
-
},
|
13
|
-
data: {
|
14
|
-
mainProtocolId: "uniswap",
|
15
|
-
},
|
16
|
-
});
|
17
|
-
await apiDbClient.rewardBreakdown.updateMany({
|
18
|
-
where: {
|
19
|
-
protocolId: "uniswapv4",
|
20
|
-
},
|
21
|
-
data: {
|
22
|
-
protocolId: "uniswap",
|
23
|
-
},
|
24
|
-
});
|
25
8
|
const protocols = await ProtocolRepository.findMany(query);
|
26
9
|
const enrichedProtocols = protocols.map(({ MainOpportunities, ...protocol }) => ({
|
27
10
|
...protocol,
|