@merkl/api 0.10.180 → 0.10.182

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.
Files changed (44) hide show
  1. package/dist/src/eden/index.d.ts +58 -12
  2. package/dist/src/index.d.ts +24 -4
  3. package/dist/src/libs/campaigns/campaignTypes/ERC20DynamicDataRefacto.js +3 -3
  4. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType.d.ts +2 -1
  5. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType.js +4 -0
  6. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/AuraProcessor.d.ts +1 -0
  7. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/AuraProcessor.js +12 -3
  8. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/PendleProcessor.d.ts +1 -1
  9. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/PendleProcessor.js +1 -3
  10. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/StakingProcessor.d.ts +39 -0
  11. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/StakingProcessor.js +45 -0
  12. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/processor/processorMapping.js +2 -0
  13. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound1RefactoFinal.d.ts +2 -1
  14. package/dist/src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound1RefactoFinal.js +25 -1
  15. package/dist/src/modules/v4/claims/claims.controller.d.ts +40 -0
  16. package/dist/src/modules/v4/claims/claims.controller.js +13 -0
  17. package/dist/src/modules/v4/claims/claims.model.d.ts +9 -0
  18. package/dist/src/modules/v4/claims/claims.model.js +1 -0
  19. package/dist/src/modules/v4/claims/claims.repository.d.ts +5 -0
  20. package/dist/src/modules/v4/claims/claims.repository.js +39 -0
  21. package/dist/src/modules/v4/claims/claims.service.d.ts +8 -0
  22. package/dist/src/modules/v4/claims/claims.service.js +31 -0
  23. package/dist/src/modules/v4/claims/index.d.ts +3 -0
  24. package/dist/src/modules/v4/claims/index.js +3 -0
  25. package/dist/src/modules/v4/router.d.ts +24 -4
  26. package/dist/src/modules/v4/router.js +3 -1
  27. package/dist/src/modules/v4/token/token.controller.d.ts +4 -4
  28. package/dist/src/modules/v4/token/token.service.d.ts +4 -4
  29. package/dist/src/modules/v4/token/token.service.js +2 -2
  30. package/dist/src/modules/v4/user/user.model.d.ts +1 -0
  31. package/dist/src/routes/v3/blacklist.d.ts +24 -4
  32. package/dist/src/routes/v3/campaigns.d.ts +24 -4
  33. package/dist/src/routes/v3/campaignsInfo.d.ts +24 -4
  34. package/dist/src/routes/v3/multiChainPositions.d.ts +24 -4
  35. package/dist/src/routes/v3/opportunity.d.ts +24 -4
  36. package/dist/src/routes/v3/positions.d.ts +24 -4
  37. package/dist/src/routes/v3/rewards.d.ts +24 -4
  38. package/dist/src/routes/v3/updates.d.ts +24 -4
  39. package/dist/src/routes/v3/userRewards.d.ts +24 -4
  40. package/dist/src/utils/decodeCalls.js +5 -1
  41. package/dist/src/utils/encodeCalls.js +13 -1
  42. package/dist/src/utils/generateCardName.js +3 -1
  43. package/dist/tsconfig.package.tsbuildinfo +1 -1
  44. package/package.json +1 -1
@@ -883,7 +883,7 @@ export declare const v4: Elysia<"/v4", false, {
883
883
  };
884
884
  headers: unknown;
885
885
  response: {
886
- 200: {
886
+ 200: ({
887
887
  symbol: string;
888
888
  name: string | null;
889
889
  id: string;
@@ -891,11 +891,11 @@ export declare const v4: Elysia<"/v4", false, {
891
891
  address: string;
892
892
  icon: string;
893
893
  decimals: number;
894
- displaySymbol: string;
895
894
  verified: boolean;
896
895
  isTest: boolean;
897
- price: number | null;
898
- }[];
896
+ } & {
897
+ price?: number | null | undefined;
898
+ })[];
899
899
  };
900
900
  };
901
901
  };
@@ -2366,6 +2366,26 @@ export declare const v4: Elysia<"/v4", false, {
2366
2366
  };
2367
2367
  };
2368
2368
  };
2369
+ } & {
2370
+ v4: {
2371
+ claims: {
2372
+ ":address": {
2373
+ get: {
2374
+ body: unknown;
2375
+ params: {
2376
+ address: string;
2377
+ };
2378
+ query: unknown;
2379
+ headers: unknown;
2380
+ response: {
2381
+ 200: (import("./claims").ClaimModel & {
2382
+ token: import("./token").Token["model"];
2383
+ })[];
2384
+ };
2385
+ };
2386
+ };
2387
+ };
2388
+ };
2369
2389
  }, {
2370
2390
  derive: {};
2371
2391
  resolve: {};
@@ -15,6 +15,7 @@ import { OTLPTraceExporter } from "@opentelemetry/exporter-trace-otlp-http";
15
15
  import { BatchSpanProcessor } from "@opentelemetry/sdk-trace-node";
16
16
  import { PrismaInstrumentation } from "@prisma/instrumentation";
17
17
  import Elysia from "elysia";
18
+ import { ClaimController } from "./claims";
18
19
  import { DynamicDataController } from "./dynamicData";
19
20
  import { InteractionController } from "./interaction/interaction.controller";
20
21
  import { LiquidityController } from "./liquidity/liquidity.controller";
@@ -59,4 +60,5 @@ export const v4 = new Elysia({ tags: ["v4"], prefix: "/v4" })
59
60
  .use(AccountingController)
60
61
  .use(DynamicDataController)
61
62
  .use(StatusController)
62
- .use(LiquidityController);
63
+ .use(LiquidityController)
64
+ .use(ClaimController);
@@ -87,7 +87,7 @@ export declare const TokenController: Elysia<"/tokens", false, {
87
87
  };
88
88
  headers: unknown;
89
89
  response: {
90
- 200: {
90
+ 200: ({
91
91
  symbol: string;
92
92
  name: string | null;
93
93
  id: string;
@@ -95,11 +95,11 @@ export declare const TokenController: Elysia<"/tokens", false, {
95
95
  address: string;
96
96
  icon: string;
97
97
  decimals: number;
98
- displaySymbol: string;
99
98
  verified: boolean;
100
99
  isTest: boolean;
101
- price: number | null;
102
- }[];
100
+ } & {
101
+ price?: number | null | undefined;
102
+ })[];
103
103
  };
104
104
  };
105
105
  };
@@ -133,7 +133,7 @@ export declare abstract class TokenService {
133
133
  * @param query
134
134
  * @returns A list of tokens
135
135
  */
136
- static findMany(query: GetTokenQueryModel): Promise<{
136
+ static findMany(query: GetTokenQueryModel): Promise<({
137
137
  symbol: string;
138
138
  name: string | null;
139
139
  id: string;
@@ -141,11 +141,11 @@ export declare abstract class TokenService {
141
141
  address: string;
142
142
  icon: string;
143
143
  decimals: number;
144
- displaySymbol: string;
145
144
  verified: boolean;
146
145
  isTest: boolean;
147
- price: number | null;
148
- }[]>;
146
+ } & {
147
+ price?: number | null | undefined;
148
+ })[]>;
149
149
  /**
150
150
  * Get value of tokens
151
151
  * @param tokenAmounts address/chain + amount of token
@@ -47,7 +47,7 @@ export class TokenService {
47
47
  * @param additionalTokens balances along with the verified ones
48
48
  */
49
49
  static async fetchVerifiedBalances(chainId, userAddress, additionalTokenAddresses) {
50
- const verifiedTokens = (await TokenService.findMany({ chainId: chainId, verified: true })).map(t => TokenService.format(t));
50
+ const verifiedTokens = await TokenService.findMany({ chainId: chainId, verified: true });
51
51
  const additionalTokens = !!additionalTokenAddresses?.length
52
52
  ? await TokenService.getManyOrCreate(additionalTokenAddresses?.map(address => ({ chainId, address })))
53
53
  : [];
@@ -222,7 +222,7 @@ export class TokenService {
222
222
  * @returns A list of tokens
223
223
  */
224
224
  static async findMany(query) {
225
- return await TokenRepository.findMany(query);
225
+ return (await TokenRepository.findMany(query)).map(TokenService.format);
226
226
  }
227
227
  /**
228
228
  * Get value of tokens
@@ -21,5 +21,6 @@ export declare const GetManyUserQuery: import("@sinclair/typebox").TObject<{
21
21
  export declare const UpdateUserTagsDto: import("@sinclair/typebox").TObject<{
22
22
  tags: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>;
23
23
  }>;
24
+ export type UserUniqueModel = typeof UserUniqueDto.static;
24
25
  export type UserModel = typeof UserDto.static;
25
26
  export type GetManyUserModel = typeof GetManyUserQuery.static;
@@ -907,7 +907,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
907
907
  };
908
908
  headers: unknown;
909
909
  response: {
910
- 200: {
910
+ 200: ({
911
911
  symbol: string;
912
912
  name: string | null;
913
913
  id: string;
@@ -915,11 +915,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
915
915
  address: string;
916
916
  icon: string;
917
917
  decimals: number;
918
- displaySymbol: string;
919
918
  verified: boolean;
920
919
  isTest: boolean;
921
- price: number | null;
922
- }[];
920
+ } & {
921
+ price?: number | null | undefined;
922
+ })[];
923
923
  };
924
924
  };
925
925
  };
@@ -2390,6 +2390,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2390
2390
  };
2391
2391
  };
2392
2392
  };
2393
+ } & {
2394
+ v4: {
2395
+ claims: {
2396
+ ":address": {
2397
+ get: {
2398
+ body: unknown;
2399
+ params: {
2400
+ address: string;
2401
+ };
2402
+ query: unknown;
2403
+ headers: unknown;
2404
+ response: {
2405
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2406
+ token: import("../../modules/v4").Token["model"];
2407
+ })[];
2408
+ };
2409
+ };
2410
+ };
2411
+ };
2412
+ };
2393
2413
  } & {
2394
2414
  index: {
2395
2415
  get: {
@@ -910,7 +910,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
910
910
  };
911
911
  headers: unknown;
912
912
  response: {
913
- 200: {
913
+ 200: ({
914
914
  symbol: string;
915
915
  name: string | null;
916
916
  id: string;
@@ -918,11 +918,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
918
918
  address: string;
919
919
  icon: string;
920
920
  decimals: number;
921
- displaySymbol: string;
922
921
  verified: boolean;
923
922
  isTest: boolean;
924
- price: number | null;
925
- }[];
923
+ } & {
924
+ price?: number | null | undefined;
925
+ })[];
926
926
  };
927
927
  };
928
928
  };
@@ -2393,6 +2393,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2393
2393
  };
2394
2394
  };
2395
2395
  };
2396
+ } & {
2397
+ v4: {
2398
+ claims: {
2399
+ ":address": {
2400
+ get: {
2401
+ body: unknown;
2402
+ params: {
2403
+ address: string;
2404
+ };
2405
+ query: unknown;
2406
+ headers: unknown;
2407
+ response: {
2408
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2409
+ token: import("../../modules/v4").Token["model"];
2410
+ })[];
2411
+ };
2412
+ };
2413
+ };
2414
+ };
2415
+ };
2396
2416
  } & {
2397
2417
  index: {
2398
2418
  get: {
@@ -901,7 +901,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
901
901
  };
902
902
  headers: unknown;
903
903
  response: {
904
- 200: {
904
+ 200: ({
905
905
  symbol: string;
906
906
  name: string | null;
907
907
  id: string;
@@ -909,11 +909,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
909
909
  address: string;
910
910
  icon: string;
911
911
  decimals: number;
912
- displaySymbol: string;
913
912
  verified: boolean;
914
913
  isTest: boolean;
915
- price: number | null;
916
- }[];
914
+ } & {
915
+ price?: number | null | undefined;
916
+ })[];
917
917
  };
918
918
  };
919
919
  };
@@ -2384,6 +2384,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2384
2384
  };
2385
2385
  };
2386
2386
  };
2387
+ } & {
2388
+ v4: {
2389
+ claims: {
2390
+ ":address": {
2391
+ get: {
2392
+ body: unknown;
2393
+ params: {
2394
+ address: string;
2395
+ };
2396
+ query: unknown;
2397
+ headers: unknown;
2398
+ response: {
2399
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2400
+ token: import("../../modules/v4").Token["model"];
2401
+ })[];
2402
+ };
2403
+ };
2404
+ };
2405
+ };
2406
+ };
2387
2407
  } & {
2388
2408
  index: {
2389
2409
  post: {
@@ -906,7 +906,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
906
906
  };
907
907
  headers: unknown;
908
908
  response: {
909
- 200: {
909
+ 200: ({
910
910
  symbol: string;
911
911
  name: string | null;
912
912
  id: string;
@@ -914,11 +914,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
914
914
  address: string;
915
915
  icon: string;
916
916
  decimals: number;
917
- displaySymbol: string;
918
917
  verified: boolean;
919
918
  isTest: boolean;
920
- price: number | null;
921
- }[];
919
+ } & {
920
+ price?: number | null | undefined;
921
+ })[];
922
922
  };
923
923
  };
924
924
  };
@@ -2389,6 +2389,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2389
2389
  };
2390
2390
  };
2391
2391
  };
2392
+ } & {
2393
+ v4: {
2394
+ claims: {
2395
+ ":address": {
2396
+ get: {
2397
+ body: unknown;
2398
+ params: {
2399
+ address: string;
2400
+ };
2401
+ query: unknown;
2402
+ headers: unknown;
2403
+ response: {
2404
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2405
+ token: import("../../modules/v4").Token["model"];
2406
+ })[];
2407
+ };
2408
+ };
2409
+ };
2410
+ };
2411
+ };
2392
2412
  } & {
2393
2413
  index: {
2394
2414
  get: {
@@ -924,7 +924,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
924
924
  };
925
925
  headers: unknown;
926
926
  response: {
927
- 200: {
927
+ 200: ({
928
928
  symbol: string;
929
929
  name: string | null;
930
930
  id: string;
@@ -932,11 +932,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
932
932
  address: string;
933
933
  icon: string;
934
934
  decimals: number;
935
- displaySymbol: string;
936
935
  verified: boolean;
937
936
  isTest: boolean;
938
- price: number | null;
939
- }[];
937
+ } & {
938
+ price?: number | null | undefined;
939
+ })[];
940
940
  };
941
941
  };
942
942
  };
@@ -2407,6 +2407,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2407
2407
  };
2408
2408
  };
2409
2409
  };
2410
+ } & {
2411
+ v4: {
2412
+ claims: {
2413
+ ":address": {
2414
+ get: {
2415
+ body: unknown;
2416
+ params: {
2417
+ address: string;
2418
+ };
2419
+ query: unknown;
2420
+ headers: unknown;
2421
+ response: {
2422
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2423
+ token: import("../../modules/v4").Token["model"];
2424
+ })[];
2425
+ };
2426
+ };
2427
+ };
2428
+ };
2429
+ };
2410
2430
  } & {
2411
2431
  index: {
2412
2432
  get: {
@@ -925,7 +925,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
925
925
  };
926
926
  headers: unknown;
927
927
  response: {
928
- 200: {
928
+ 200: ({
929
929
  symbol: string;
930
930
  name: string | null;
931
931
  id: string;
@@ -933,11 +933,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
933
933
  address: string;
934
934
  icon: string;
935
935
  decimals: number;
936
- displaySymbol: string;
937
936
  verified: boolean;
938
937
  isTest: boolean;
939
- price: number | null;
940
- }[];
938
+ } & {
939
+ price?: number | null | undefined;
940
+ })[];
941
941
  };
942
942
  };
943
943
  };
@@ -2408,6 +2408,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2408
2408
  };
2409
2409
  };
2410
2410
  };
2411
+ } & {
2412
+ v4: {
2413
+ claims: {
2414
+ ":address": {
2415
+ get: {
2416
+ body: unknown;
2417
+ params: {
2418
+ address: string;
2419
+ };
2420
+ query: unknown;
2421
+ headers: unknown;
2422
+ response: {
2423
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2424
+ token: import("../../modules/v4").Token["model"];
2425
+ })[];
2426
+ };
2427
+ };
2428
+ };
2429
+ };
2430
+ };
2411
2431
  } & {
2412
2432
  index: {
2413
2433
  get: {
@@ -907,7 +907,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
907
907
  };
908
908
  headers: unknown;
909
909
  response: {
910
- 200: {
910
+ 200: ({
911
911
  symbol: string;
912
912
  name: string | null;
913
913
  id: string;
@@ -915,11 +915,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
915
915
  address: string;
916
916
  icon: string;
917
917
  decimals: number;
918
- displaySymbol: string;
919
918
  verified: boolean;
920
919
  isTest: boolean;
921
- price: number | null;
922
- }[];
920
+ } & {
921
+ price?: number | null | undefined;
922
+ })[];
923
923
  };
924
924
  };
925
925
  };
@@ -2390,6 +2390,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2390
2390
  };
2391
2391
  };
2392
2392
  };
2393
+ } & {
2394
+ v4: {
2395
+ claims: {
2396
+ ":address": {
2397
+ get: {
2398
+ body: unknown;
2399
+ params: {
2400
+ address: string;
2401
+ };
2402
+ query: unknown;
2403
+ headers: unknown;
2404
+ response: {
2405
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2406
+ token: import("../../modules/v4").Token["model"];
2407
+ })[];
2408
+ };
2409
+ };
2410
+ };
2411
+ };
2412
+ };
2393
2413
  } & {
2394
2414
  index: {
2395
2415
  get: {
@@ -908,7 +908,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
908
908
  };
909
909
  headers: unknown;
910
910
  response: {
911
- 200: {
911
+ 200: ({
912
912
  symbol: string;
913
913
  name: string | null;
914
914
  id: string;
@@ -916,11 +916,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
916
916
  address: string;
917
917
  icon: string;
918
918
  decimals: number;
919
- displaySymbol: string;
920
919
  verified: boolean;
921
920
  isTest: boolean;
922
- price: number | null;
923
- }[];
921
+ } & {
922
+ price?: number | null | undefined;
923
+ })[];
924
924
  };
925
925
  };
926
926
  };
@@ -2391,6 +2391,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2391
2391
  };
2392
2392
  };
2393
2393
  };
2394
+ } & {
2395
+ v4: {
2396
+ claims: {
2397
+ ":address": {
2398
+ get: {
2399
+ body: unknown;
2400
+ params: {
2401
+ address: string;
2402
+ };
2403
+ query: unknown;
2404
+ headers: unknown;
2405
+ response: {
2406
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2407
+ token: import("../../modules/v4").Token["model"];
2408
+ })[];
2409
+ };
2410
+ };
2411
+ };
2412
+ };
2413
+ };
2394
2414
  } & {
2395
2415
  index: {
2396
2416
  get: {
@@ -910,7 +910,7 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
910
910
  };
911
911
  headers: unknown;
912
912
  response: {
913
- 200: {
913
+ 200: ({
914
914
  symbol: string;
915
915
  name: string | null;
916
916
  id: string;
@@ -918,11 +918,11 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
918
918
  address: string;
919
919
  icon: string;
920
920
  decimals: number;
921
- displaySymbol: string;
922
921
  verified: boolean;
923
922
  isTest: boolean;
924
- price: number | null;
925
- }[];
923
+ } & {
924
+ price?: number | null | undefined;
925
+ })[];
926
926
  };
927
927
  };
928
928
  };
@@ -2393,6 +2393,26 @@ declare const _default: (app: App) => import("elysia").default<"", false, {
2393
2393
  };
2394
2394
  };
2395
2395
  };
2396
+ } & {
2397
+ v4: {
2398
+ claims: {
2399
+ ":address": {
2400
+ get: {
2401
+ body: unknown;
2402
+ params: {
2403
+ address: string;
2404
+ };
2405
+ query: unknown;
2406
+ headers: unknown;
2407
+ response: {
2408
+ 200: (import("../../modules/v4/claims").ClaimModel & {
2409
+ token: import("../../modules/v4").Token["model"];
2410
+ })[];
2411
+ };
2412
+ };
2413
+ };
2414
+ };
2415
+ };
2396
2416
  } & {
2397
2417
  index: {
2398
2418
  get: {
@@ -1,4 +1,4 @@
1
- import { AaveInterface, AuraInterface, AuraOperatorInterface, BalancerGaugeInterface, BalancerPoolInterface, BalancerVaultInterface, BeefyInterface, CompoundInterface, CurveInterface, DefutureVaultInterface, ERC20Interface, EnzymeInterface, EulerInterface, FactoryInterface, FluidInterface, FraxlendInterface, GearboxVaultInterface, IonicInterface, LayerBankInterface, MaverickBPLensInterface, MetamorphoInterface, MoonwellInterface, OneInchStakingInterface, PendleInterface, PendleYTInterface, RadiantInterface, RfxInterface, RswEthStrategyInterface, SturdyInterface, SymetricAmbientStrategyInterface, TorosInterface, UniswapV2PoolInterface, ZFStableLPINterface, ZFStableSwapThreePoolInterface, } from "@sdk";
1
+ import { AaveInterface, AuraInterface, AuraOperatorInterface, BalancerGaugeInterface, BalancerPoolInterface, BalancerVaultInterface, BeefyInterface, CompoundInterface, CurveInterface, DefutureVaultInterface, ERC20Interface, EnzymeInterface, EulerInterface, FactoryInterface, FluidInterface, FraxlendInterface, GearboxVaultInterface, IonicInterface, LayerBankInterface, MaverickBPLensInterface, MetamorphoInterface, MoonwellInterface, OneInchStakingInterface, PendleInterface, PendleYTInterface, RadiantInterface, RfxInterface, RswEthStrategyInterface, SturdyInterface, SymetricAmbientStrategyInterface, TorosInterface, UniswapV2PoolInterface, VePufferInterface, ZFStableLPINterface, ZFStableSwapThreePoolInterface, } from "@sdk";
2
2
  import { tokenType } from "../libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType";
3
3
  export function decodeCall(calls, index, key, type) {
4
4
  const returnData = calls[index];
@@ -195,8 +195,12 @@ export function decodeCall(calls, index, key, type) {
195
195
  default:
196
196
  return SymetricAmbientStrategyInterface.decodeFunctionResult("getPositions", returnData);
197
197
  }
198
+ case "lockNFT":
199
+ return VePufferInterface.decodeFunctionResult("lockNFT", returnData)[0];
198
200
  case "tvl":
199
201
  return DefutureVaultInterface.decodeFunctionResult("tvl", returnData)[0];
202
+ case "eip712DomainName":
203
+ return MetamorphoInterface.decodeFunctionResult("eip712Domain", returnData)[1];
200
204
  default:
201
205
  throw new Error(`Key not recognized for ${key}`);
202
206
  }
@@ -1,5 +1,5 @@
1
1
  import { tokenType } from "../libs/campaigns/campaignTypes/ERC20SubTypes/helpers/tokenType";
2
- import { AaveInterface, AuraInterface, AuraOperatorInterface, BalancerGaugeInterface, BalancerPoolInterface, BalancerVaultInterface, BeefyInterface, CompoundInterface, CurveInterface, DefutureVaultInterface, ERC20Interface, EnzymeInterface, EulerInterface, FactoryInterface, FluidInterface, FraxlendInterface, GearboxVaultInterface, IonicInterface, LayerBankInterface, MaverickBPLensInterface, MetamorphoInterface, MoonwellInterface, OneInchStakingInterface, PendleInterface, PendleYTInterface, RadiantInterface, RfxDatastoreInterface, RswEthStrategyInterface, SturdyInterface, SymetricAmbientStrategyInterface, TorosInterface, UniswapV2PoolInterface, ZFStableLPINterface, ZFStableSwapThreePoolInterface, } from "@sdk";
2
+ import { AaveInterface, AuraInterface, AuraOperatorInterface, BalancerGaugeInterface, BalancerPoolInterface, BalancerVaultInterface, BeefyInterface, CompoundInterface, CurveInterface, DefutureVaultInterface, ERC20Interface, EnzymeInterface, EulerInterface, FactoryInterface, FluidInterface, FraxlendInterface, GearboxVaultInterface, IonicInterface, LayerBankInterface, MaverickBPLensInterface, MetamorphoInterface, MoonwellInterface, OneInchStakingInterface, PendleInterface, PendleYTInterface, RadiantInterface, RfxDatastoreInterface, RswEthStrategyInterface, SturdyInterface, SymetricAmbientStrategyInterface, TorosInterface, UniswapV2PoolInterface, VePufferInterface, ZFStableLPINterface, ZFStableSwapThreePoolInterface, } from "@sdk";
3
3
  import { fluidInterface } from "src/libs/campaigns/campaignTypes/ERC20SubTypes/subtypesRound1";
4
4
  export function createCall(target, key, type, metaData) {
5
5
  switch (key) {
@@ -307,6 +307,18 @@ export function createCall(target, key, type, metaData) {
307
307
  callData: DefutureVaultInterface.encodeFunctionData("tvl"),
308
308
  target: target,
309
309
  };
310
+ case "lockNFT":
311
+ return {
312
+ allowFailure: true,
313
+ callData: VePufferInterface.encodeFunctionData("lockNFT"),
314
+ target: target,
315
+ };
316
+ case "eip712DomainName":
317
+ return {
318
+ allowFailure: true,
319
+ callData: MetamorphoInterface.encodeFunctionData("eip712Domain"),
320
+ target: target,
321
+ };
310
322
  default:
311
323
  throw new Error(`Unknown key ${key}`);
312
324
  }
@@ -16,7 +16,7 @@ export function generateCardName(type, typeInfo, campaign, symbols = [""]) {
16
16
  case tokenType.pancakeswap:
17
17
  return `${typeInfo.protocol} ${typeInfo.symbolToken0}/${typeInfo.symbolToken1}`;
18
18
  case tokenType.pendleYT:
19
- return `Hold YT of ${typeInfo.symbolUnderlyingToken} on ${typeInfo.protocol}`;
19
+ return `Hold ${typeInfo.protocol} ${typeInfo.name}`;
20
20
  case tokenType.pendle:
21
21
  return `Provide ${typeInfo.symbolUnderlyingToken} on ${typeInfo.protocol}`;
22
22
  case tokenType.balancerGauge:
@@ -96,6 +96,8 @@ export function generateCardName(type, typeInfo, campaign, symbols = [""]) {
96
96
  case tokenType.tempestStaking:
97
97
  case tokenType.holdstation:
98
98
  return `Hold vault token ${campaign.campaignParameters.symbolTargetToken} on ${typeInfo.protocol}`;
99
+ case tokenType.staking:
100
+ return `${typeInfo.lockNFT !== undefined ? "Lock" : "Stake"} ${campaign.campaignParameters.symbolTargetToken} on ${typeInfo.stakingSymbol}`;
99
101
  default:
100
102
  return `Hold ${typeInfo.name} (${campaign.campaignParameters.symbolTargetToken})`;
101
103
  }