@merkl/api 0.10.80 → 0.10.82
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/.generated/index.d.ts +8 -53
- package/dist/database/api/.generated/package.json +1 -1
- package/dist/database/api/.generated/schema.prisma +1 -2
- package/dist/src/cache/declaration.d.ts +5 -0
- package/dist/src/eden/index.d.ts +66 -316
- package/dist/src/index.d.ts +24 -120
- package/dist/src/libs/campaigns/campaignTypes/ERC20DynamicDataRefacto.d.ts +3 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType.d.ts +16 -1
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/AaveProcessor.d.ts +30 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/AssetProcessor.d.ts +35 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/AuraProcessor.d.ts +61 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/BalancerGaugeProcessor.d.ts +49 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/BalancerPoolProcessor.d.ts +53 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/BeefyProcessor.d.ts +48 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/CompoundProcessor.d.ts +44 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/EnzymeProcessor.d.ts +40 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/EulerBorrowProcessor.d.ts +37 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/EulerLendProcessor.d.ts +37 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/FluidProcessor.d.ts +39 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/FraxProcessor.d.ts +33 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/GearboxProcessor.d.ts +40 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/MetamorphoProcessor.d.ts +31 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/PendleProcessor.d.ts +27 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/RadiantProcessor.d.ts +32 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/SpliceProcessor.d.ts +16 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/SturdySiloProcessor.d.ts +39 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/TorosProcessor.d.ts +29 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/curveProcessor.d.ts +47 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/genericProcessor.d.ts +61 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/processorMapping.d.ts +6 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/templateProcessor.d.ts +32 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/uniswapProcessor.d.ts +42 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesPricesRefactoFinal.d.ts +4 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound1RefactoFinal.d.ts +3 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound2RefactoFinal.d.ts +3 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound3RefactoFinal.d.ts +3 -0
- package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound4RefactoFinal.d.ts +4 -0
- package/dist/src/libs/campaigns/campaignsDynamicDataRefacto.d.ts +3 -0
- package/dist/src/modules/v4/opportunity/opportunity.controller.d.ts +0 -3
- package/dist/src/modules/v4/opportunity/opportunity.repository.d.ts +0 -16
- package/dist/src/modules/v4/opportunity/opportunity.service.d.ts +0 -4
- package/dist/src/modules/v4/reward/reward.repository.d.ts +1 -0
- package/dist/src/modules/v4/reward/reward.service.d.ts +126 -109
- package/dist/src/modules/v4/router.d.ts +24 -120
- package/dist/src/modules/v4/testdynamicData/dynamicData.controller.d.ts +50 -0
- package/dist/src/modules/v4/testdynamicData/dynamicData.model.d.ts +5 -0
- package/dist/src/modules/v4/testdynamicData/dynamicData.repository.d.ts +0 -0
- package/dist/src/modules/v4/testdynamicData/dynamicData.service.d.ts +12 -0
- package/dist/src/modules/v4/testdynamicData/index.d.ts +3 -0
- package/dist/src/modules/v4/token/token.repository.d.ts +1 -1
- package/dist/src/modules/v4/user/user.controller.d.ts +2 -2
- package/dist/src/routes/v3/ERC20Campaigns.d.ts +24 -120
- package/dist/src/routes/v3/blacklist.d.ts +24 -120
- package/dist/src/routes/v3/campaigns.d.ts +24 -120
- package/dist/src/routes/v3/campaignsInfo.d.ts +24 -120
- package/dist/src/routes/v3/multiChainPositions.d.ts +24 -120
- package/dist/src/routes/v3/opportunity.d.ts +24 -120
- package/dist/src/routes/v3/positions.d.ts +24 -120
- package/dist/src/routes/v3/rewards.d.ts +24 -120
- package/dist/src/routes/v3/updates.d.ts +24 -120
- package/dist/src/routes/v3/userRewards.d.ts +24 -120
- package/dist/src/utils/decodeCalls.d.ts +2 -0
- package/dist/src/utils/encodeCalls.d.ts +3 -0
- package/dist/src/utils/generateCardName.d.ts +3 -0
- package/dist/src/utils/interfaces.d.ts +39 -0
- package/dist/tsconfig.package.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -74,7 +74,7 @@ export declare abstract class RewardService {
|
|
|
74
74
|
* @param reward straight from db
|
|
75
75
|
* @returns a Reward model
|
|
76
76
|
*/
|
|
77
|
-
static format(
|
|
77
|
+
static format(rewards: Awaited<ReturnType<typeof RewardRepository.getByRecipient>>): {
|
|
78
78
|
token: {
|
|
79
79
|
id: string;
|
|
80
80
|
name: string | null;
|
|
@@ -148,10 +148,10 @@ export declare abstract class RewardService {
|
|
|
148
148
|
root: string;
|
|
149
149
|
recipient: string;
|
|
150
150
|
proofs: string[];
|
|
151
|
-
};
|
|
151
|
+
}[];
|
|
152
152
|
static createManyBreakdown(data: CreateManyBreakdownModel): Promise<import("../../../../database/api/.generated").Prisma.BatchPayload>;
|
|
153
|
-
static getByRecipient(recipient: string, roots: string[], withToken?: boolean): Promise<{
|
|
154
|
-
|
|
153
|
+
static getByRecipient(recipient: string, roots: string[], withToken?: boolean): Promise<({
|
|
154
|
+
RewardToken: {
|
|
155
155
|
id: string;
|
|
156
156
|
name: string | null;
|
|
157
157
|
chainId: number;
|
|
@@ -162,69 +162,77 @@ export declare abstract class RewardService {
|
|
|
162
162
|
verified: boolean;
|
|
163
163
|
price: number | null;
|
|
164
164
|
};
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
165
|
+
Breakdown: ({
|
|
166
|
+
Campaign: {
|
|
167
|
+
identifier: string;
|
|
168
|
+
campaignId: string;
|
|
169
|
+
Opportunity: {
|
|
170
|
+
Chain: {
|
|
171
|
+
id: number;
|
|
172
|
+
name: string;
|
|
173
|
+
icon: string;
|
|
174
|
+
};
|
|
175
|
+
Tokens: {
|
|
176
|
+
id: string;
|
|
177
|
+
name: string | null;
|
|
178
|
+
chainId: number;
|
|
179
|
+
address: string;
|
|
180
|
+
decimals: number;
|
|
181
|
+
symbol: string;
|
|
182
|
+
icon: string;
|
|
183
|
+
verified: boolean;
|
|
184
|
+
price: number | null;
|
|
185
|
+
}[];
|
|
186
|
+
Protocols: {
|
|
187
|
+
id: string;
|
|
188
|
+
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
189
|
+
name: string;
|
|
190
|
+
description: string;
|
|
191
|
+
url: string;
|
|
192
|
+
icon: string;
|
|
193
|
+
}[];
|
|
194
|
+
MainProtocol: {
|
|
195
|
+
id: string;
|
|
196
|
+
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
197
|
+
name: string;
|
|
198
|
+
description: string;
|
|
199
|
+
url: string;
|
|
200
|
+
icon: string;
|
|
201
|
+
} | null;
|
|
202
|
+
} & {
|
|
174
203
|
id: string;
|
|
175
|
-
name: string | null;
|
|
176
204
|
chainId: number;
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
symbol: string;
|
|
180
|
-
icon: string;
|
|
181
|
-
verified: boolean;
|
|
182
|
-
price: number | null;
|
|
183
|
-
}[];
|
|
184
|
-
Protocols: {
|
|
185
|
-
id: string;
|
|
186
|
-
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
187
|
-
name: string;
|
|
188
|
-
description: string;
|
|
189
|
-
url: string;
|
|
190
|
-
icon: string;
|
|
191
|
-
}[];
|
|
192
|
-
MainProtocol: {
|
|
193
|
-
id: string;
|
|
194
|
-
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
205
|
+
type: import("../../../../database/api/.generated").$Enums.CampaignType;
|
|
206
|
+
identifier: string;
|
|
195
207
|
name: string;
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
identifier: string;
|
|
205
|
-
name: string;
|
|
206
|
-
status: import("../../../../database/api/.generated").$Enums.Status;
|
|
207
|
-
action: import("../../../../database/api/.generated").$Enums.OpportunityAction;
|
|
208
|
-
mainProtocolId: string | null;
|
|
209
|
-
tvl: number;
|
|
210
|
-
apr: number;
|
|
211
|
-
dailyRewards: number;
|
|
212
|
-
tags: string[];
|
|
208
|
+
status: import("../../../../database/api/.generated").$Enums.Status;
|
|
209
|
+
action: import("../../../../database/api/.generated").$Enums.OpportunityAction;
|
|
210
|
+
mainProtocolId: string | null;
|
|
211
|
+
tvl: number;
|
|
212
|
+
apr: number;
|
|
213
|
+
dailyRewards: number;
|
|
214
|
+
tags: string[];
|
|
215
|
+
};
|
|
213
216
|
};
|
|
217
|
+
} & {
|
|
218
|
+
id: number;
|
|
219
|
+
protocolId: string | null;
|
|
214
220
|
reason: string;
|
|
215
221
|
amount: string;
|
|
216
222
|
claimed: string;
|
|
217
223
|
pending: string;
|
|
218
224
|
auxiliaryData1: string | null;
|
|
219
225
|
auxiliaryData2: string | null;
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
226
|
+
rewardId: string;
|
|
227
|
+
campaignId: string;
|
|
228
|
+
})[];
|
|
229
|
+
} & {
|
|
230
|
+
id: string;
|
|
224
231
|
root: string;
|
|
225
232
|
recipient: string;
|
|
233
|
+
rewardTokenId: string;
|
|
226
234
|
proofs: string[];
|
|
227
|
-
}[]>;
|
|
235
|
+
})[]>;
|
|
228
236
|
/**
|
|
229
237
|
* Groups a breakdown array by their corresponding opportunities
|
|
230
238
|
* @param breakdowns with campaignIds
|
|
@@ -247,7 +255,7 @@ export declare abstract class RewardService {
|
|
|
247
255
|
*/
|
|
248
256
|
static splitRewardsBreakdownByOpportunity(rewards: Awaited<ReturnType<typeof RewardService.getUserRewardsByChain>>): (Omit<{
|
|
249
257
|
chain: Chain;
|
|
250
|
-
rewards: Awaited<ReturnType<(typeof RewardService)["
|
|
258
|
+
rewards: Awaited<ReturnType<(typeof RewardService)["format"]>>;
|
|
251
259
|
}, "rewards"> & {
|
|
252
260
|
rewards: (Omit<{
|
|
253
261
|
token: {
|
|
@@ -337,7 +345,7 @@ export declare abstract class RewardService {
|
|
|
337
345
|
})[];
|
|
338
346
|
static removeOpportunityFromRewardBreakdown(rewards: Awaited<ReturnType<typeof RewardService.getUserRewardsByChain>>): (Omit<{
|
|
339
347
|
chain: Chain;
|
|
340
|
-
rewards: Awaited<ReturnType<(typeof RewardService)["
|
|
348
|
+
rewards: Awaited<ReturnType<(typeof RewardService)["format"]>>;
|
|
341
349
|
}, "rewards"> & {
|
|
342
350
|
rewards: (Omit<{
|
|
343
351
|
token: {
|
|
@@ -425,8 +433,9 @@ export declare abstract class RewardService {
|
|
|
425
433
|
}[];
|
|
426
434
|
})[];
|
|
427
435
|
})[];
|
|
428
|
-
static
|
|
429
|
-
|
|
436
|
+
static findManyRootsOnChain(chainId: ChainId): Promise<any>;
|
|
437
|
+
static checkLastClaim(chainId: number, user: string, roots: CacheKeys["CurrentRoot"]["returns"], rewards: Awaited<ReturnType<typeof RewardService.getByRecipient>>): Promise<({
|
|
438
|
+
RewardToken: {
|
|
430
439
|
id: string;
|
|
431
440
|
name: string | null;
|
|
432
441
|
chainId: number;
|
|
@@ -437,72 +446,80 @@ export declare abstract class RewardService {
|
|
|
437
446
|
verified: boolean;
|
|
438
447
|
price: number | null;
|
|
439
448
|
};
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
+
Breakdown: ({
|
|
450
|
+
Campaign: {
|
|
451
|
+
identifier: string;
|
|
452
|
+
campaignId: string;
|
|
453
|
+
Opportunity: {
|
|
454
|
+
Chain: {
|
|
455
|
+
id: number;
|
|
456
|
+
name: string;
|
|
457
|
+
icon: string;
|
|
458
|
+
};
|
|
459
|
+
Tokens: {
|
|
460
|
+
id: string;
|
|
461
|
+
name: string | null;
|
|
462
|
+
chainId: number;
|
|
463
|
+
address: string;
|
|
464
|
+
decimals: number;
|
|
465
|
+
symbol: string;
|
|
466
|
+
icon: string;
|
|
467
|
+
verified: boolean;
|
|
468
|
+
price: number | null;
|
|
469
|
+
}[];
|
|
470
|
+
Protocols: {
|
|
471
|
+
id: string;
|
|
472
|
+
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
473
|
+
name: string;
|
|
474
|
+
description: string;
|
|
475
|
+
url: string;
|
|
476
|
+
icon: string;
|
|
477
|
+
}[];
|
|
478
|
+
MainProtocol: {
|
|
479
|
+
id: string;
|
|
480
|
+
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
481
|
+
name: string;
|
|
482
|
+
description: string;
|
|
483
|
+
url: string;
|
|
484
|
+
icon: string;
|
|
485
|
+
} | null;
|
|
486
|
+
} & {
|
|
449
487
|
id: string;
|
|
450
|
-
name: string | null;
|
|
451
488
|
chainId: number;
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
symbol: string;
|
|
455
|
-
icon: string;
|
|
456
|
-
verified: boolean;
|
|
457
|
-
price: number | null;
|
|
458
|
-
}[];
|
|
459
|
-
Protocols: {
|
|
460
|
-
id: string;
|
|
461
|
-
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
462
|
-
name: string;
|
|
463
|
-
description: string;
|
|
464
|
-
url: string;
|
|
465
|
-
icon: string;
|
|
466
|
-
}[];
|
|
467
|
-
MainProtocol: {
|
|
468
|
-
id: string;
|
|
469
|
-
tags: import("../../../../database/api/.generated").$Enums.ProtocolTag[];
|
|
489
|
+
type: import("../../../../database/api/.generated").$Enums.CampaignType;
|
|
490
|
+
identifier: string;
|
|
470
491
|
name: string;
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
identifier: string;
|
|
480
|
-
name: string;
|
|
481
|
-
status: import("../../../../database/api/.generated").$Enums.Status;
|
|
482
|
-
action: import("../../../../database/api/.generated").$Enums.OpportunityAction;
|
|
483
|
-
mainProtocolId: string | null;
|
|
484
|
-
tvl: number;
|
|
485
|
-
apr: number;
|
|
486
|
-
dailyRewards: number;
|
|
487
|
-
tags: string[];
|
|
492
|
+
status: import("../../../../database/api/.generated").$Enums.Status;
|
|
493
|
+
action: import("../../../../database/api/.generated").$Enums.OpportunityAction;
|
|
494
|
+
mainProtocolId: string | null;
|
|
495
|
+
tvl: number;
|
|
496
|
+
apr: number;
|
|
497
|
+
dailyRewards: number;
|
|
498
|
+
tags: string[];
|
|
499
|
+
};
|
|
488
500
|
};
|
|
501
|
+
} & {
|
|
502
|
+
id: number;
|
|
503
|
+
protocolId: string | null;
|
|
489
504
|
reason: string;
|
|
490
505
|
amount: string;
|
|
491
506
|
claimed: string;
|
|
492
507
|
pending: string;
|
|
493
508
|
auxiliaryData1: string | null;
|
|
494
509
|
auxiliaryData2: string | null;
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
510
|
+
rewardId: string;
|
|
511
|
+
campaignId: string;
|
|
512
|
+
})[];
|
|
513
|
+
} & {
|
|
514
|
+
id: string;
|
|
499
515
|
root: string;
|
|
500
516
|
recipient: string;
|
|
517
|
+
rewardTokenId: string;
|
|
501
518
|
proofs: string[];
|
|
502
|
-
}[]>;
|
|
519
|
+
})[]>;
|
|
503
520
|
static getUserRewardsByChain(user: string, withToken: boolean, chainFilter?: ChainId[]): Promise<{
|
|
504
521
|
chain: Chain;
|
|
505
|
-
rewards: Awaited<ReturnType<(typeof RewardService)["
|
|
522
|
+
rewards: Awaited<ReturnType<(typeof RewardService)["format"]>>;
|
|
506
523
|
}[]>;
|
|
507
524
|
static updatePendings(data: UpdatePendingModel): Promise<boolean>;
|
|
508
525
|
static count(): Promise<Record<string, {
|
|
@@ -62,7 +62,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
62
62
|
200: {
|
|
63
63
|
aprRecord: {
|
|
64
64
|
cumulated: number;
|
|
65
|
-
cummulated: number;
|
|
66
65
|
timestamp: bigint;
|
|
67
66
|
breakdowns: {
|
|
68
67
|
id: number;
|
|
@@ -150,7 +149,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
150
149
|
200: {
|
|
151
150
|
aprRecord: {
|
|
152
151
|
cumulated: number;
|
|
153
|
-
cummulated: number;
|
|
154
152
|
timestamp: bigint;
|
|
155
153
|
breakdowns: {
|
|
156
154
|
id: number;
|
|
@@ -248,7 +246,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
248
246
|
200: ({
|
|
249
247
|
aprRecord: {
|
|
250
248
|
cumulated: number;
|
|
251
|
-
cummulated: number;
|
|
252
249
|
timestamp: bigint;
|
|
253
250
|
breakdowns: {
|
|
254
251
|
id: number;
|
|
@@ -1166,7 +1163,7 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
1166
1163
|
response: {
|
|
1167
1164
|
200: (Omit<{
|
|
1168
1165
|
chain: import("../../../database/api/.generated").Chain;
|
|
1169
|
-
rewards: Awaited<ReturnType<typeof import("./reward").RewardService["
|
|
1166
|
+
rewards: Awaited<ReturnType<typeof import("./reward").RewardService["format"]>>;
|
|
1170
1167
|
}, "rewards"> & {
|
|
1171
1168
|
rewards: (Omit<{
|
|
1172
1169
|
token: {
|
|
@@ -1276,7 +1273,7 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
1276
1273
|
response: {
|
|
1277
1274
|
200: (Omit<{
|
|
1278
1275
|
chain: import("../../../database/api/.generated").Chain;
|
|
1279
|
-
rewards: Awaited<ReturnType<typeof import("./reward").RewardService["
|
|
1276
|
+
rewards: Awaited<ReturnType<typeof import("./reward").RewardService["format"]>>;
|
|
1280
1277
|
}, "rewards"> & {
|
|
1281
1278
|
rewards: (Omit<{
|
|
1282
1279
|
token: {
|
|
@@ -1732,127 +1729,34 @@ export declare const v4: Elysia<"/v4", false, {
|
|
|
1732
1729
|
};
|
|
1733
1730
|
} & {
|
|
1734
1731
|
v4: {
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
post: {
|
|
1738
|
-
body: {
|
|
1739
|
-
status: {
|
|
1740
|
-
value: "SUCCESS";
|
|
1741
|
-
computedUntil: number;
|
|
1742
|
-
} | {
|
|
1743
|
-
value: "PROCESSING";
|
|
1744
|
-
} | {
|
|
1745
|
-
error: string;
|
|
1746
|
-
details: string;
|
|
1747
|
-
value: "SKIPPED";
|
|
1748
|
-
} | {
|
|
1749
|
-
error: string;
|
|
1750
|
-
details: string;
|
|
1751
|
-
value: "FAILED";
|
|
1752
|
-
};
|
|
1753
|
-
campaignId: string;
|
|
1754
|
-
distributionChain: number;
|
|
1755
|
-
};
|
|
1756
|
-
params: Record<never, string>;
|
|
1757
|
-
query: unknown;
|
|
1758
|
-
headers: {
|
|
1759
|
-
authorization: string;
|
|
1760
|
-
};
|
|
1761
|
-
response: {
|
|
1762
|
-
200: void;
|
|
1763
|
-
};
|
|
1764
|
-
};
|
|
1765
|
-
};
|
|
1766
|
-
};
|
|
1767
|
-
} & {
|
|
1768
|
-
campaignStatus: {
|
|
1769
|
-
index: {
|
|
1770
|
-
get: {
|
|
1771
|
-
body: unknown;
|
|
1772
|
-
params: Record<never, string>;
|
|
1773
|
-
query: unknown;
|
|
1774
|
-
headers: unknown;
|
|
1775
|
-
response: {
|
|
1776
|
-
200: {
|
|
1777
|
-
campaignId: string;
|
|
1778
|
-
computedUntil: bigint;
|
|
1779
|
-
processingStarted: bigint;
|
|
1780
|
-
status: import("../../../database/api/.generated").$Enums.RunStatus;
|
|
1781
|
-
error: string;
|
|
1782
|
-
details: import("../../../database/api/.generated").Prisma.JsonValue;
|
|
1783
|
-
}[];
|
|
1784
|
-
};
|
|
1785
|
-
};
|
|
1786
|
-
};
|
|
1787
|
-
};
|
|
1788
|
-
} & {
|
|
1789
|
-
campaignStatus: {
|
|
1790
|
-
unique: {
|
|
1791
|
-
get: {
|
|
1792
|
-
body: unknown;
|
|
1793
|
-
params: Record<never, string>;
|
|
1794
|
-
query: {
|
|
1795
|
-
identifier: string;
|
|
1796
|
-
distributionChain: number;
|
|
1797
|
-
};
|
|
1798
|
-
headers: unknown;
|
|
1799
|
-
response: {
|
|
1800
|
-
200: {
|
|
1801
|
-
campaignId: string;
|
|
1802
|
-
computedUntil: bigint;
|
|
1803
|
-
processingStarted: bigint;
|
|
1804
|
-
status: import("../../../database/api/.generated").$Enums.RunStatus;
|
|
1805
|
-
error: string;
|
|
1806
|
-
details: import("../../../database/api/.generated").Prisma.JsonValue;
|
|
1807
|
-
};
|
|
1808
|
-
};
|
|
1809
|
-
};
|
|
1810
|
-
};
|
|
1811
|
-
};
|
|
1812
|
-
} & {
|
|
1813
|
-
campaignStatus: {
|
|
1814
|
-
computeChain: {
|
|
1732
|
+
dynamicData: {
|
|
1733
|
+
chainId: {
|
|
1815
1734
|
":chainId": {
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1735
|
+
token: {
|
|
1736
|
+
":tokenAddress": {
|
|
1737
|
+
get: {
|
|
1738
|
+
body: unknown;
|
|
1739
|
+
params: {
|
|
1740
|
+
chainId: string;
|
|
1741
|
+
tokenAddress: string;
|
|
1742
|
+
};
|
|
1743
|
+
query: unknown;
|
|
1744
|
+
headers: unknown;
|
|
1745
|
+
response: {
|
|
1746
|
+
200: {
|
|
1747
|
+
tvl: number;
|
|
1748
|
+
totalSupply: number;
|
|
1749
|
+
cardName: string;
|
|
1750
|
+
blacklistedSupply: number;
|
|
1751
|
+
priceTargetToken: number;
|
|
1752
|
+
};
|
|
1753
|
+
};
|
|
1754
|
+
};
|
|
1832
1755
|
};
|
|
1833
1756
|
};
|
|
1834
1757
|
};
|
|
1835
1758
|
};
|
|
1836
1759
|
};
|
|
1837
|
-
} & {
|
|
1838
|
-
campaignStatus: {
|
|
1839
|
-
overlaps: {
|
|
1840
|
-
get: {
|
|
1841
|
-
body: unknown;
|
|
1842
|
-
params: Record<never, string>;
|
|
1843
|
-
query: {
|
|
1844
|
-
identifier: string;
|
|
1845
|
-
distributionChain: number;
|
|
1846
|
-
};
|
|
1847
|
-
headers: {
|
|
1848
|
-
authorization: string;
|
|
1849
|
-
};
|
|
1850
|
-
response: {
|
|
1851
|
-
200: boolean;
|
|
1852
|
-
};
|
|
1853
|
-
};
|
|
1854
|
-
};
|
|
1855
|
-
};
|
|
1856
1760
|
};
|
|
1857
1761
|
}, {
|
|
1858
1762
|
derive: {};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import Elysia from "elysia";
|
|
2
|
+
export declare const DynamicDataController: Elysia<"/dynamicData", false, {
|
|
3
|
+
decorator: {};
|
|
4
|
+
store: {};
|
|
5
|
+
derive: {};
|
|
6
|
+
resolve: {};
|
|
7
|
+
}, {
|
|
8
|
+
type: {};
|
|
9
|
+
error: {};
|
|
10
|
+
}, {
|
|
11
|
+
schema: {};
|
|
12
|
+
macro: {};
|
|
13
|
+
}, {
|
|
14
|
+
dynamicData: {
|
|
15
|
+
chainId: {
|
|
16
|
+
":chainId": {
|
|
17
|
+
token: {
|
|
18
|
+
":tokenAddress": {
|
|
19
|
+
get: {
|
|
20
|
+
body: unknown;
|
|
21
|
+
params: {
|
|
22
|
+
chainId: string;
|
|
23
|
+
tokenAddress: string;
|
|
24
|
+
};
|
|
25
|
+
query: unknown;
|
|
26
|
+
headers: unknown;
|
|
27
|
+
response: {
|
|
28
|
+
200: {
|
|
29
|
+
tvl: number;
|
|
30
|
+
totalSupply: number;
|
|
31
|
+
cardName: string;
|
|
32
|
+
blacklistedSupply: number;
|
|
33
|
+
priceTargetToken: number;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
}, {
|
|
43
|
+
derive: {};
|
|
44
|
+
resolve: {};
|
|
45
|
+
schema: {};
|
|
46
|
+
}, {
|
|
47
|
+
derive: {};
|
|
48
|
+
resolve: {};
|
|
49
|
+
schema: {};
|
|
50
|
+
}>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const DynamicDataSourceIdentifier: import("@sinclair/typebox").TObject<{
|
|
2
|
+
chainId: import("@sinclair/typebox").TString;
|
|
3
|
+
tokenAddress: import("@sinclair/typebox").TString;
|
|
4
|
+
}>;
|
|
5
|
+
export type PriceSourceIdentifierModel = typeof DynamicDataSourceIdentifier.static;
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
type output = {
|
|
2
|
+
tvl: number;
|
|
3
|
+
totalSupply: number;
|
|
4
|
+
cardName: string;
|
|
5
|
+
blacklistedSupply: number;
|
|
6
|
+
priceTargetToken: number;
|
|
7
|
+
};
|
|
8
|
+
export declare class DynamicDataService {
|
|
9
|
+
/** Fetches a single price */
|
|
10
|
+
static queryERC20DynamicData(chainId: string, tokenAddress: string): Promise<output>;
|
|
11
|
+
}
|
|
12
|
+
export {};
|
|
@@ -64,7 +64,7 @@ export declare const UserController: Elysia<"/users", false, {
|
|
|
64
64
|
response: {
|
|
65
65
|
200: (Omit<{
|
|
66
66
|
chain: import("../../../../database/api/.generated").Chain;
|
|
67
|
-
rewards: Awaited<ReturnType<(typeof RewardService)["
|
|
67
|
+
rewards: Awaited<ReturnType<(typeof RewardService)["format"]>>;
|
|
68
68
|
}, "rewards"> & {
|
|
69
69
|
rewards: (Omit<{
|
|
70
70
|
token: {
|
|
@@ -174,7 +174,7 @@ export declare const UserController: Elysia<"/users", false, {
|
|
|
174
174
|
response: {
|
|
175
175
|
200: (Omit<{
|
|
176
176
|
chain: import("../../../../database/api/.generated").Chain;
|
|
177
|
-
rewards: Awaited<ReturnType<(typeof RewardService)["
|
|
177
|
+
rewards: Awaited<ReturnType<(typeof RewardService)["format"]>>;
|
|
178
178
|
}, "rewards"> & {
|
|
179
179
|
rewards: (Omit<{
|
|
180
180
|
token: {
|