@merkl/api 0.21.32 → 0.21.33
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/src/eden/index.d.ts +80 -0
- package/dist/src/engine/deprecated/erc20SubTypeProcessors/helpers/factoryFinder.js +1 -1
- package/dist/src/engine/deprecated/erc20SubTypeProcessors/implementations/curveProcessor.js +6 -2
- package/dist/src/engine/deprecated/erc20SubTypeProcessors/implementations/processorMapping.js +1 -0
- package/dist/src/engine/deprecated/erc20SubTypeProcessors/tokenTypeToProtocolAndAction.js +4 -0
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/euler/tvl.js +5 -1
- package/dist/src/engine/implementations/Erc20/subTypes/index.d.ts +2 -1
- package/dist/src/engine/implementations/Erc20/subTypes/index.js +1 -0
- package/dist/src/guards/BackOffice.guard.d.ts +1 -1
- package/dist/src/guards/BackOffice.guard.js +1 -1
- package/dist/src/guards/Engine.guard.d.ts +1 -1
- package/dist/src/guards/Engine.guard.js +2 -3
- package/dist/src/guards/VerifyJwt.guard.d.ts +10 -0
- package/dist/src/guards/VerifyJwt.guard.js +13 -0
- package/dist/src/index.d.ts +32 -0
- package/dist/src/index.js +2 -0
- package/dist/src/modules/v4/accounting/accounting.controller.js +7 -13
- package/dist/src/modules/v4/authentication/authentication.controller.d.ts +52 -0
- package/dist/src/modules/v4/authentication/authentication.controller.js +23 -0
- package/dist/src/modules/v4/authentication/authentication.model.d.ts +10 -0
- package/dist/src/modules/v4/authentication/authentication.model.js +6 -0
- package/dist/src/modules/v4/authentication/authentication.service.d.ts +10 -0
- package/dist/src/modules/v4/authentication/authentication.service.js +31 -0
- package/dist/src/modules/v4/blacklist/blacklist.controller.js +2 -2
- package/dist/src/modules/v4/cache/cache.repository.d.ts +3 -0
- package/dist/src/modules/v4/cache/cache.repository.js +9 -0
- package/dist/src/modules/v4/cache/cache.service.d.ts +3 -0
- package/dist/src/modules/v4/cache/cache.service.js +9 -0
- package/dist/src/modules/v4/opportunity/opportunity.controller.js +1 -3
- package/dist/src/modules/v4/reward/reward.controller.js +13 -4
- package/dist/src/modules/v4/router.d.ts +32 -0
- package/dist/src/modules/v4/router.js +3 -1
- package/dist/src/modules/v4/token/token.controller.js +1 -1
- package/dist/src/modules/v4/uniswap/uniswap.controller.js +1 -1
- package/dist/src/utils/decodeCalls.js +15 -5
- package/dist/src/utils/generateCardName.js +1 -0
- package/dist/tsconfig.package.tsbuildinfo +1 -1
- package/package.json +4 -3
@@ -94,7 +94,7 @@ export const TokenController = new Elysia({ prefix: "/tokens", detail: { tags: [
|
|
94
94
|
body: CreateTokenDto,
|
95
95
|
headers: AuthorizationHeadersDto,
|
96
96
|
beforeHandle: async ({ headers, body }) => {
|
97
|
-
|
97
|
+
BackOfficeGuard({ headers });
|
98
98
|
body.address = throwOnInvalidRequiredAddress(body.address);
|
99
99
|
throwOnUnsupportedChainId(body.chainId);
|
100
100
|
},
|
@@ -91,7 +91,7 @@ export const UniswapController = new Elysia({
|
|
91
91
|
params: ChainUniqueDto,
|
92
92
|
headers: AuthorizationHeadersDto,
|
93
93
|
beforeHandle: async ({ params, headers }) => {
|
94
|
-
|
94
|
+
BackOfficeGuard({ headers });
|
95
95
|
if (!UniV4ChainIdArray.includes(params.chainId))
|
96
96
|
throw new UnsupportedNetwork(params.chainId);
|
97
97
|
},
|
@@ -193,11 +193,21 @@ export function decodeReturnValue(returnData, key, type) {
|
|
193
193
|
case "coin2":
|
194
194
|
return CurveInterface.decodeFunctionResult("coins", returnData)[0];
|
195
195
|
case "N_COINS":
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
196
|
+
switch (type) {
|
197
|
+
case Erc20SubType.curveTricrypto:
|
198
|
+
try {
|
199
|
+
return CurveStableSwapNGInterface.decodeFunctionResult("N_COINS", returnData)[0];
|
200
|
+
}
|
201
|
+
catch (e) {
|
202
|
+
return 3;
|
203
|
+
}
|
204
|
+
default:
|
205
|
+
try {
|
206
|
+
return CurveStableSwapNGInterface.decodeFunctionResult("N_COINS", returnData)[0];
|
207
|
+
}
|
208
|
+
catch (e) {
|
209
|
+
return 2;
|
210
|
+
}
|
201
211
|
}
|
202
212
|
case "balances":
|
203
213
|
return CurveStableSwapNGInterface.decodeFunctionResult("balances", returnData)[0];
|
@@ -160,6 +160,7 @@ export function generateCardName(type, typeInfo, campaign, symbols = [""], displ
|
|
160
160
|
}
|
161
161
|
return `${typeInfo.name}`;
|
162
162
|
case Erc20SubType.curveNPool:
|
163
|
+
case Erc20SubType.curveTricrypto:
|
163
164
|
return `Curve ${typeInfo.name}`;
|
164
165
|
case Erc20SubType.vicuna: {
|
165
166
|
const parsedName = typeInfo.name.split(" ");
|