@compass-labs/api-sdk 0.5.13 → 0.5.14
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/README.md +9 -0
- package/bin/mcp-server.js +751 -264
- package/bin/mcp-server.js.map +20 -10
- package/dist/commonjs/funcs/transactionBatchingAaveLoop.d.ts +28 -0
- package/dist/commonjs/funcs/transactionBatchingAaveLoop.d.ts.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingAaveLoop.js +128 -0
- package/dist/commonjs/funcs/transactionBatchingAaveLoop.js.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingAuthorization.d.ts +23 -0
- package/dist/commonjs/funcs/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingAuthorization.js +123 -0
- package/dist/commonjs/funcs/transactionBatchingAuthorization.js.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.d.ts +24 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.js +124 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.js.map +1 -0
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/lib/files.d.ts +5 -0
- package/dist/commonjs/lib/files.d.ts.map +1 -1
- package/dist/commonjs/lib/files.js +41 -0
- package/dist/commonjs/lib/files.js.map +1 -1
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/server.js +7 -1
- package/dist/commonjs/mcp-server/server.js.map +1 -1
- package/dist/commonjs/mcp-server/tools/transactionBatchingAaveLoop.d.ts +8 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAaveLoop.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAaveLoop.js +74 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAaveLoop.js.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.d.ts +8 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.js +69 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.js.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.d.ts +8 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.js +70 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.js.map +1 -0
- package/dist/commonjs/models/components/aavelooprequest.d.ts +181 -0
- package/dist/commonjs/models/components/aavelooprequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/aavelooprequest.js +199 -0
- package/dist/commonjs/models/components/aavelooprequest.js.map +1 -0
- package/dist/commonjs/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.d.ts +8 -8
- package/dist/commonjs/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.d.ts.map +1 -1
- package/dist/commonjs/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.js +8 -8
- package/dist/commonjs/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +4 -0
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +4 -0
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/metadata.d.ts +0 -4
- package/dist/commonjs/models/components/metadata.d.ts.map +1 -1
- package/dist/commonjs/models/components/metadata.js +0 -4
- package/dist/commonjs/models/components/metadata.js.map +1 -1
- package/dist/commonjs/models/components/multicallauthorizationrequest.d.ts +49 -0
- package/dist/commonjs/models/components/multicallauthorizationrequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationrequest.js +72 -0
- package/dist/commonjs/models/components/multicallauthorizationrequest.js.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.d.ts +45 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.js +73 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.js.map +1 -0
- package/dist/commonjs/models/components/multicallexecuterequest.d.ts +50 -0
- package/dist/commonjs/models/components/multicallexecuterequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallexecuterequest.js +87 -0
- package/dist/commonjs/models/components/multicallexecuterequest.js.map +1 -0
- package/dist/commonjs/sdk/sdk.d.ts +3 -0
- package/dist/commonjs/sdk/sdk.d.ts.map +1 -1
- package/dist/commonjs/sdk/sdk.js +4 -0
- package/dist/commonjs/sdk/sdk.js.map +1 -1
- package/dist/commonjs/sdk/transactionbatching.d.ts +47 -0
- package/dist/commonjs/sdk/transactionbatching.d.ts.map +1 -0
- package/dist/commonjs/sdk/transactionbatching.js +63 -0
- package/dist/commonjs/sdk/transactionbatching.js.map +1 -0
- package/dist/esm/funcs/transactionBatchingAaveLoop.d.ts +28 -0
- package/dist/esm/funcs/transactionBatchingAaveLoop.d.ts.map +1 -0
- package/dist/esm/funcs/transactionBatchingAaveLoop.js +92 -0
- package/dist/esm/funcs/transactionBatchingAaveLoop.js.map +1 -0
- package/dist/esm/funcs/transactionBatchingAuthorization.d.ts +23 -0
- package/dist/esm/funcs/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/esm/funcs/transactionBatchingAuthorization.js +87 -0
- package/dist/esm/funcs/transactionBatchingAuthorization.js.map +1 -0
- package/dist/esm/funcs/transactionBatchingExecute.d.ts +24 -0
- package/dist/esm/funcs/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/esm/funcs/transactionBatchingExecute.js +88 -0
- package/dist/esm/funcs/transactionBatchingExecute.js.map +1 -0
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/lib/files.d.ts +5 -0
- package/dist/esm/lib/files.d.ts.map +1 -1
- package/dist/esm/lib/files.js +40 -0
- package/dist/esm/lib/files.js.map +1 -1
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.d.ts.map +1 -1
- package/dist/esm/mcp-server/server.js +7 -1
- package/dist/esm/mcp-server/server.js.map +1 -1
- package/dist/esm/mcp-server/tools/transactionBatchingAaveLoop.d.ts +8 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAaveLoop.d.ts.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAaveLoop.js +38 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAaveLoop.js.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.d.ts +8 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.js +33 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.js.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.d.ts +8 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.js +34 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.js.map +1 -0
- package/dist/esm/models/components/aavelooprequest.d.ts +181 -0
- package/dist/esm/models/components/aavelooprequest.d.ts.map +1 -0
- package/dist/esm/models/components/aavelooprequest.js +153 -0
- package/dist/esm/models/components/aavelooprequest.js.map +1 -0
- package/dist/esm/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.d.ts +8 -8
- package/dist/esm/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.d.ts.map +1 -1
- package/dist/esm/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.js +8 -8
- package/dist/esm/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +4 -0
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +4 -0
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/metadata.d.ts +0 -4
- package/dist/esm/models/components/metadata.d.ts.map +1 -1
- package/dist/esm/models/components/metadata.js +0 -4
- package/dist/esm/models/components/metadata.js.map +1 -1
- package/dist/esm/models/components/multicallauthorizationrequest.d.ts +49 -0
- package/dist/esm/models/components/multicallauthorizationrequest.d.ts.map +1 -0
- package/dist/esm/models/components/multicallauthorizationrequest.js +34 -0
- package/dist/esm/models/components/multicallauthorizationrequest.js.map +1 -0
- package/dist/esm/models/components/multicallauthorizationresponse.d.ts +45 -0
- package/dist/esm/models/components/multicallauthorizationresponse.d.ts.map +1 -0
- package/dist/esm/models/components/multicallauthorizationresponse.js +35 -0
- package/dist/esm/models/components/multicallauthorizationresponse.js.map +1 -0
- package/dist/esm/models/components/multicallexecuterequest.d.ts +50 -0
- package/dist/esm/models/components/multicallexecuterequest.d.ts.map +1 -0
- package/dist/esm/models/components/multicallexecuterequest.js +49 -0
- package/dist/esm/models/components/multicallexecuterequest.js.map +1 -0
- package/dist/esm/sdk/sdk.d.ts +3 -0
- package/dist/esm/sdk/sdk.d.ts.map +1 -1
- package/dist/esm/sdk/sdk.js +4 -0
- package/dist/esm/sdk/sdk.js.map +1 -1
- package/dist/esm/sdk/transactionbatching.d.ts +47 -0
- package/dist/esm/sdk/transactionbatching.d.ts.map +1 -0
- package/dist/esm/sdk/transactionbatching.js +59 -0
- package/dist/esm/sdk/transactionbatching.js.map +1 -0
- package/docs/sdks/transactionbatching/README.md +318 -0
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/transactionBatchingAaveLoop.ts +179 -0
- package/src/funcs/transactionBatchingAuthorization.ts +175 -0
- package/src/funcs/transactionBatchingExecute.ts +175 -0
- package/src/lib/config.ts +3 -3
- package/src/lib/files.ts +42 -0
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +7 -1
- package/src/mcp-server/tools/transactionBatchingAaveLoop.ts +47 -0
- package/src/mcp-server/tools/transactionBatchingAuthorization.ts +44 -0
- package/src/mcp-server/tools/transactionBatchingExecute.ts +43 -0
- package/src/models/components/aavelooprequest.ts +368 -0
- package/src/models/components/compassapibackendmodelsmorphoreadresponsegetmarketmarketstate.ts +16 -16
- package/src/models/components/index.ts +4 -0
- package/src/models/components/metadata.ts +0 -8
- package/src/models/components/multicallauthorizationrequest.ts +90 -0
- package/src/models/components/multicallauthorizationresponse.ts +88 -0
- package/src/models/components/multicallexecuterequest.ts +112 -0
- package/src/sdk/sdk.ts +8 -0
- package/src/sdk/transactionbatching.ts +84 -0
package/bin/mcp-server.js
CHANGED
|
@@ -34205,9 +34205,9 @@ var init_config = __esm(() => {
|
|
|
34205
34205
|
SDK_METADATA = {
|
|
34206
34206
|
language: "typescript",
|
|
34207
34207
|
openapiDocVersion: "0.0.1",
|
|
34208
|
-
sdkVersion: "0.5.
|
|
34209
|
-
genVersion: "2.
|
|
34210
|
-
userAgent: "speakeasy-sdk/typescript 0.5.
|
|
34208
|
+
sdkVersion: "0.5.14",
|
|
34209
|
+
genVersion: "2.628.0",
|
|
34210
|
+
userAgent: "speakeasy-sdk/typescript 0.5.14 2.628.0 0.0.1 @compass-labs/api-sdk"
|
|
34211
34211
|
};
|
|
34212
34212
|
});
|
|
34213
34213
|
|
|
@@ -36248,6 +36248,128 @@ var init_aaveliquiditychangeresponse = __esm(() => {
|
|
|
36248
36248
|
})(AaveLiquidityChangeResponse$ ||= {});
|
|
36249
36249
|
});
|
|
36250
36250
|
|
|
36251
|
+
// src/models/components/signedauthorization.ts
|
|
36252
|
+
var R$inboundSchema, R$outboundSchema, R$, S$inboundSchema, S$outboundSchema, S$, SignedAuthorization$inboundSchema, SignedAuthorization$outboundSchema, SignedAuthorization$;
|
|
36253
|
+
var init_signedauthorization = __esm(() => {
|
|
36254
|
+
init_esm();
|
|
36255
|
+
R$inboundSchema = unionType([
|
|
36256
|
+
numberType().int(),
|
|
36257
|
+
stringType()
|
|
36258
|
+
]);
|
|
36259
|
+
R$outboundSchema = unionType([numberType().int(), stringType()]);
|
|
36260
|
+
((R$) => {
|
|
36261
|
+
R$.inboundSchema = R$inboundSchema;
|
|
36262
|
+
R$.outboundSchema = R$outboundSchema;
|
|
36263
|
+
})(R$ ||= {});
|
|
36264
|
+
S$inboundSchema = unionType([
|
|
36265
|
+
numberType().int(),
|
|
36266
|
+
stringType()
|
|
36267
|
+
]);
|
|
36268
|
+
S$outboundSchema = unionType([numberType().int(), stringType()]);
|
|
36269
|
+
((S$) => {
|
|
36270
|
+
S$.inboundSchema = S$inboundSchema;
|
|
36271
|
+
S$.outboundSchema = S$outboundSchema;
|
|
36272
|
+
})(S$ ||= {});
|
|
36273
|
+
SignedAuthorization$inboundSchema = objectType({
|
|
36274
|
+
nonce: numberType().int(),
|
|
36275
|
+
address: stringType(),
|
|
36276
|
+
chainId: numberType().int(),
|
|
36277
|
+
r: unionType([numberType().int(), stringType()]),
|
|
36278
|
+
s: unionType([numberType().int(), stringType()]),
|
|
36279
|
+
yParity: numberType().int()
|
|
36280
|
+
});
|
|
36281
|
+
SignedAuthorization$outboundSchema = objectType({
|
|
36282
|
+
nonce: numberType().int(),
|
|
36283
|
+
address: stringType(),
|
|
36284
|
+
chainId: numberType().int(),
|
|
36285
|
+
r: unionType([numberType().int(), stringType()]),
|
|
36286
|
+
s: unionType([numberType().int(), stringType()]),
|
|
36287
|
+
yParity: numberType().int()
|
|
36288
|
+
});
|
|
36289
|
+
((SignedAuthorization$) => {
|
|
36290
|
+
SignedAuthorization$.inboundSchema = SignedAuthorization$inboundSchema;
|
|
36291
|
+
SignedAuthorization$.outboundSchema = SignedAuthorization$outboundSchema;
|
|
36292
|
+
})(SignedAuthorization$ ||= {});
|
|
36293
|
+
});
|
|
36294
|
+
|
|
36295
|
+
// src/models/components/aavelooprequest.ts
|
|
36296
|
+
var InitialCollateralAmount$inboundSchema, InitialCollateralAmount$outboundSchema, InitialCollateralAmount$, Multiplier$inboundSchema, Multiplier$outboundSchema, Multiplier$, MaxSlippagePercent$inboundSchema, MaxSlippagePercent$outboundSchema, MaxSlippagePercent$, LoanToValue$inboundSchema, LoanToValue$outboundSchema, LoanToValue$, AaveLoopRequest$inboundSchema, AaveLoopRequest$outboundSchema, AaveLoopRequest$;
|
|
36297
|
+
var init_aavelooprequest = __esm(() => {
|
|
36298
|
+
init_esm();
|
|
36299
|
+
init_primitives();
|
|
36300
|
+
init_chain();
|
|
36301
|
+
init_signedauthorization();
|
|
36302
|
+
init_tokenenum();
|
|
36303
|
+
InitialCollateralAmount$inboundSchema = unionType([numberType(), stringType()]);
|
|
36304
|
+
InitialCollateralAmount$outboundSchema = unionType([numberType(), stringType()]);
|
|
36305
|
+
((InitialCollateralAmount$) => {
|
|
36306
|
+
InitialCollateralAmount$.inboundSchema = InitialCollateralAmount$inboundSchema;
|
|
36307
|
+
InitialCollateralAmount$.outboundSchema = InitialCollateralAmount$outboundSchema;
|
|
36308
|
+
})(InitialCollateralAmount$ ||= {});
|
|
36309
|
+
Multiplier$inboundSchema = unionType([numberType(), stringType()]);
|
|
36310
|
+
Multiplier$outboundSchema = unionType([numberType(), stringType()]);
|
|
36311
|
+
((Multiplier$) => {
|
|
36312
|
+
Multiplier$.inboundSchema = Multiplier$inboundSchema;
|
|
36313
|
+
Multiplier$.outboundSchema = Multiplier$outboundSchema;
|
|
36314
|
+
})(Multiplier$ ||= {});
|
|
36315
|
+
MaxSlippagePercent$inboundSchema = unionType([numberType(), stringType()]);
|
|
36316
|
+
MaxSlippagePercent$outboundSchema = unionType([numberType(), stringType()]);
|
|
36317
|
+
((MaxSlippagePercent$) => {
|
|
36318
|
+
MaxSlippagePercent$.inboundSchema = MaxSlippagePercent$inboundSchema;
|
|
36319
|
+
MaxSlippagePercent$.outboundSchema = MaxSlippagePercent$outboundSchema;
|
|
36320
|
+
})(MaxSlippagePercent$ ||= {});
|
|
36321
|
+
LoanToValue$inboundSchema = unionType([numberType(), stringType()]);
|
|
36322
|
+
LoanToValue$outboundSchema = unionType([numberType(), stringType()]);
|
|
36323
|
+
((LoanToValue$) => {
|
|
36324
|
+
LoanToValue$.inboundSchema = LoanToValue$inboundSchema;
|
|
36325
|
+
LoanToValue$.outboundSchema = LoanToValue$outboundSchema;
|
|
36326
|
+
})(LoanToValue$ ||= {});
|
|
36327
|
+
AaveLoopRequest$inboundSchema = objectType({
|
|
36328
|
+
chain: Chain$inboundSchema,
|
|
36329
|
+
sender: stringType(),
|
|
36330
|
+
signed_authorization: SignedAuthorization$inboundSchema,
|
|
36331
|
+
collateral_token: TokenEnum$inboundSchema,
|
|
36332
|
+
borrow_token: TokenEnum$inboundSchema,
|
|
36333
|
+
initial_collateral_amount: unionType([numberType(), stringType()]),
|
|
36334
|
+
multiplier: unionType([numberType(), stringType()]),
|
|
36335
|
+
max_slippage_percent: unionType([numberType(), stringType()]),
|
|
36336
|
+
loan_to_value: unionType([numberType(), stringType()])
|
|
36337
|
+
}).transform((v2) => {
|
|
36338
|
+
return remap(v2, {
|
|
36339
|
+
signed_authorization: "signedAuthorization",
|
|
36340
|
+
collateral_token: "collateralToken",
|
|
36341
|
+
borrow_token: "borrowToken",
|
|
36342
|
+
initial_collateral_amount: "initialCollateralAmount",
|
|
36343
|
+
max_slippage_percent: "maxSlippagePercent",
|
|
36344
|
+
loan_to_value: "loanToValue"
|
|
36345
|
+
});
|
|
36346
|
+
});
|
|
36347
|
+
AaveLoopRequest$outboundSchema = objectType({
|
|
36348
|
+
chain: Chain$outboundSchema,
|
|
36349
|
+
sender: stringType(),
|
|
36350
|
+
signedAuthorization: SignedAuthorization$outboundSchema,
|
|
36351
|
+
collateralToken: TokenEnum$outboundSchema,
|
|
36352
|
+
borrowToken: TokenEnum$outboundSchema,
|
|
36353
|
+
initialCollateralAmount: unionType([numberType(), stringType()]),
|
|
36354
|
+
multiplier: unionType([numberType(), stringType()]),
|
|
36355
|
+
maxSlippagePercent: unionType([numberType(), stringType()]),
|
|
36356
|
+
loanToValue: unionType([numberType(), stringType()])
|
|
36357
|
+
}).transform((v2) => {
|
|
36358
|
+
return remap(v2, {
|
|
36359
|
+
signedAuthorization: "signed_authorization",
|
|
36360
|
+
collateralToken: "collateral_token",
|
|
36361
|
+
borrowToken: "borrow_token",
|
|
36362
|
+
initialCollateralAmount: "initial_collateral_amount",
|
|
36363
|
+
maxSlippagePercent: "max_slippage_percent",
|
|
36364
|
+
loanToValue: "loan_to_value"
|
|
36365
|
+
});
|
|
36366
|
+
});
|
|
36367
|
+
((AaveLoopRequest$) => {
|
|
36368
|
+
AaveLoopRequest$.inboundSchema = AaveLoopRequest$inboundSchema;
|
|
36369
|
+
AaveLoopRequest$.outboundSchema = AaveLoopRequest$outboundSchema;
|
|
36370
|
+
})(AaveLoopRequest$ ||= {});
|
|
36371
|
+
});
|
|
36372
|
+
|
|
36251
36373
|
// src/models/components/aaverateresponse.ts
|
|
36252
36374
|
var AaveRateResponse$inboundSchema, AaveRateResponse$outboundSchema, AaveRateResponse$;
|
|
36253
36375
|
var init_aaverateresponse = __esm(() => {
|
|
@@ -39361,25 +39483,25 @@ var init_compassapibackendmodelsmorphoreadresponsegetmarketmarketstate = __esm((
|
|
|
39361
39483
|
init_esm();
|
|
39362
39484
|
CompassApiBackendModelsMorphoReadResponseGetMarketMarketState$inboundSchema = objectType({
|
|
39363
39485
|
utilization: stringType(),
|
|
39364
|
-
collateralAssets: stringType(),
|
|
39486
|
+
collateralAssets: nullableType(stringType()).optional(),
|
|
39365
39487
|
collateralAssetsUsd: nullableType(stringType()).optional(),
|
|
39366
39488
|
borrowAssets: stringType(),
|
|
39367
|
-
borrowAssetsUsd: stringType(),
|
|
39489
|
+
borrowAssetsUsd: nullableType(stringType()).optional(),
|
|
39368
39490
|
liquidityAssets: stringType(),
|
|
39369
|
-
liquidityAssetsUsd: stringType(),
|
|
39491
|
+
liquidityAssetsUsd: nullableType(stringType()).optional(),
|
|
39370
39492
|
totalLiquidity: stringType(),
|
|
39371
|
-
totalLiquidityUsd: stringType()
|
|
39493
|
+
totalLiquidityUsd: nullableType(stringType()).optional()
|
|
39372
39494
|
});
|
|
39373
39495
|
CompassApiBackendModelsMorphoReadResponseGetMarketMarketState$outboundSchema = objectType({
|
|
39374
39496
|
utilization: stringType(),
|
|
39375
|
-
collateralAssets: stringType(),
|
|
39497
|
+
collateralAssets: nullableType(stringType()).optional(),
|
|
39376
39498
|
collateralAssetsUsd: nullableType(stringType()).optional(),
|
|
39377
39499
|
borrowAssets: stringType(),
|
|
39378
|
-
borrowAssetsUsd: stringType(),
|
|
39500
|
+
borrowAssetsUsd: nullableType(stringType()).optional(),
|
|
39379
39501
|
liquidityAssets: stringType(),
|
|
39380
|
-
liquidityAssetsUsd: stringType(),
|
|
39502
|
+
liquidityAssetsUsd: nullableType(stringType()).optional(),
|
|
39381
39503
|
totalLiquidity: stringType(),
|
|
39382
|
-
totalLiquidityUsd: stringType()
|
|
39504
|
+
totalLiquidityUsd: nullableType(stringType()).optional()
|
|
39383
39505
|
});
|
|
39384
39506
|
((CompassApiBackendModelsMorphoReadResponseGetMarketMarketState$) => {
|
|
39385
39507
|
CompassApiBackendModelsMorphoReadResponseGetMarketMarketState$.inboundSchema = CompassApiBackendModelsMorphoReadResponseGetMarketMarketState$inboundSchema;
|
|
@@ -39887,14 +40009,10 @@ var init_metadata = __esm(() => {
|
|
|
39887
40009
|
init_esm();
|
|
39888
40010
|
init_curator();
|
|
39889
40011
|
Metadata$inboundSchema = objectType({
|
|
39890
|
-
description: nullableType(stringType()),
|
|
39891
|
-
image: nullableType(stringType()),
|
|
39892
40012
|
forumLink: nullableType(stringType()),
|
|
39893
40013
|
curators: arrayType(Curator$inboundSchema)
|
|
39894
40014
|
});
|
|
39895
40015
|
Metadata$outboundSchema = objectType({
|
|
39896
|
-
description: nullableType(stringType()),
|
|
39897
|
-
image: nullableType(stringType()),
|
|
39898
40016
|
forumLink: nullableType(stringType()),
|
|
39899
40017
|
curators: arrayType(Curator$outboundSchema)
|
|
39900
40018
|
});
|
|
@@ -40649,6 +40767,79 @@ var init_morphowithdrawrequest = __esm(() => {
|
|
|
40649
40767
|
})(MorphoWithdrawRequest$ ||= {});
|
|
40650
40768
|
});
|
|
40651
40769
|
|
|
40770
|
+
// src/models/components/multicallauthorizationrequest.ts
|
|
40771
|
+
var MulticallAuthorizationRequest$inboundSchema, MulticallAuthorizationRequest$outboundSchema, MulticallAuthorizationRequest$;
|
|
40772
|
+
var init_multicallauthorizationrequest = __esm(() => {
|
|
40773
|
+
init_esm();
|
|
40774
|
+
init_chain();
|
|
40775
|
+
MulticallAuthorizationRequest$inboundSchema = objectType({
|
|
40776
|
+
chain: Chain$inboundSchema,
|
|
40777
|
+
sender: stringType()
|
|
40778
|
+
});
|
|
40779
|
+
MulticallAuthorizationRequest$outboundSchema = objectType({
|
|
40780
|
+
chain: Chain$outboundSchema,
|
|
40781
|
+
sender: stringType()
|
|
40782
|
+
});
|
|
40783
|
+
((MulticallAuthorizationRequest$) => {
|
|
40784
|
+
MulticallAuthorizationRequest$.inboundSchema = MulticallAuthorizationRequest$inboundSchema;
|
|
40785
|
+
MulticallAuthorizationRequest$.outboundSchema = MulticallAuthorizationRequest$outboundSchema;
|
|
40786
|
+
})(MulticallAuthorizationRequest$ ||= {});
|
|
40787
|
+
});
|
|
40788
|
+
|
|
40789
|
+
// src/models/components/multicallauthorizationresponse.ts
|
|
40790
|
+
var MulticallAuthorizationResponse$inboundSchema, MulticallAuthorizationResponse$outboundSchema, MulticallAuthorizationResponse$;
|
|
40791
|
+
var init_multicallauthorizationresponse = __esm(() => {
|
|
40792
|
+
init_esm();
|
|
40793
|
+
MulticallAuthorizationResponse$inboundSchema = objectType({
|
|
40794
|
+
nonce: numberType().int(),
|
|
40795
|
+
address: stringType(),
|
|
40796
|
+
chainId: numberType().int()
|
|
40797
|
+
});
|
|
40798
|
+
MulticallAuthorizationResponse$outboundSchema = objectType({
|
|
40799
|
+
nonce: numberType().int(),
|
|
40800
|
+
address: stringType(),
|
|
40801
|
+
chainId: numberType().int()
|
|
40802
|
+
});
|
|
40803
|
+
((MulticallAuthorizationResponse$) => {
|
|
40804
|
+
MulticallAuthorizationResponse$.inboundSchema = MulticallAuthorizationResponse$inboundSchema;
|
|
40805
|
+
MulticallAuthorizationResponse$.outboundSchema = MulticallAuthorizationResponse$outboundSchema;
|
|
40806
|
+
})(MulticallAuthorizationResponse$ ||= {});
|
|
40807
|
+
});
|
|
40808
|
+
|
|
40809
|
+
// src/models/components/multicallexecuterequest.ts
|
|
40810
|
+
var MulticallExecuteRequest$inboundSchema, MulticallExecuteRequest$outboundSchema, MulticallExecuteRequest$;
|
|
40811
|
+
var init_multicallexecuterequest = __esm(() => {
|
|
40812
|
+
init_esm();
|
|
40813
|
+
init_primitives();
|
|
40814
|
+
init_chain();
|
|
40815
|
+
init_signedauthorization();
|
|
40816
|
+
init_useroperation();
|
|
40817
|
+
MulticallExecuteRequest$inboundSchema = objectType({
|
|
40818
|
+
chain: Chain$inboundSchema,
|
|
40819
|
+
sender: stringType(),
|
|
40820
|
+
signed_authorization: SignedAuthorization$inboundSchema,
|
|
40821
|
+
actions: arrayType(UserOperation$inboundSchema)
|
|
40822
|
+
}).transform((v2) => {
|
|
40823
|
+
return remap(v2, {
|
|
40824
|
+
signed_authorization: "signedAuthorization"
|
|
40825
|
+
});
|
|
40826
|
+
});
|
|
40827
|
+
MulticallExecuteRequest$outboundSchema = objectType({
|
|
40828
|
+
chain: Chain$outboundSchema,
|
|
40829
|
+
sender: stringType(),
|
|
40830
|
+
signedAuthorization: SignedAuthorization$outboundSchema,
|
|
40831
|
+
actions: arrayType(UserOperation$outboundSchema)
|
|
40832
|
+
}).transform((v2) => {
|
|
40833
|
+
return remap(v2, {
|
|
40834
|
+
signedAuthorization: "signed_authorization"
|
|
40835
|
+
});
|
|
40836
|
+
});
|
|
40837
|
+
((MulticallExecuteRequest$) => {
|
|
40838
|
+
MulticallExecuteRequest$.inboundSchema = MulticallExecuteRequest$inboundSchema;
|
|
40839
|
+
MulticallExecuteRequest$.outboundSchema = MulticallExecuteRequest$outboundSchema;
|
|
40840
|
+
})(MulticallExecuteRequest$ ||= {});
|
|
40841
|
+
});
|
|
40842
|
+
|
|
40652
40843
|
// src/models/components/openposition.ts
|
|
40653
40844
|
var OpenPosition$inboundSchema, OpenPosition$outboundSchema, OpenPosition$;
|
|
40654
40845
|
var init_openposition = __esm(() => {
|
|
@@ -41236,50 +41427,6 @@ var init_security2 = __esm(() => {
|
|
|
41236
41427
|
})(Security$ ||= {});
|
|
41237
41428
|
});
|
|
41238
41429
|
|
|
41239
|
-
// src/models/components/signedauthorization.ts
|
|
41240
|
-
var R$inboundSchema, R$outboundSchema, R$, S$inboundSchema, S$outboundSchema, S$, SignedAuthorization$inboundSchema, SignedAuthorization$outboundSchema, SignedAuthorization$;
|
|
41241
|
-
var init_signedauthorization = __esm(() => {
|
|
41242
|
-
init_esm();
|
|
41243
|
-
R$inboundSchema = unionType([
|
|
41244
|
-
numberType().int(),
|
|
41245
|
-
stringType()
|
|
41246
|
-
]);
|
|
41247
|
-
R$outboundSchema = unionType([numberType().int(), stringType()]);
|
|
41248
|
-
((R$) => {
|
|
41249
|
-
R$.inboundSchema = R$inboundSchema;
|
|
41250
|
-
R$.outboundSchema = R$outboundSchema;
|
|
41251
|
-
})(R$ ||= {});
|
|
41252
|
-
S$inboundSchema = unionType([
|
|
41253
|
-
numberType().int(),
|
|
41254
|
-
stringType()
|
|
41255
|
-
]);
|
|
41256
|
-
S$outboundSchema = unionType([numberType().int(), stringType()]);
|
|
41257
|
-
((S$) => {
|
|
41258
|
-
S$.inboundSchema = S$inboundSchema;
|
|
41259
|
-
S$.outboundSchema = S$outboundSchema;
|
|
41260
|
-
})(S$ ||= {});
|
|
41261
|
-
SignedAuthorization$inboundSchema = objectType({
|
|
41262
|
-
nonce: numberType().int(),
|
|
41263
|
-
address: stringType(),
|
|
41264
|
-
chainId: numberType().int(),
|
|
41265
|
-
r: unionType([numberType().int(), stringType()]),
|
|
41266
|
-
s: unionType([numberType().int(), stringType()]),
|
|
41267
|
-
yParity: numberType().int()
|
|
41268
|
-
});
|
|
41269
|
-
SignedAuthorization$outboundSchema = objectType({
|
|
41270
|
-
nonce: numberType().int(),
|
|
41271
|
-
address: stringType(),
|
|
41272
|
-
chainId: numberType().int(),
|
|
41273
|
-
r: unionType([numberType().int(), stringType()]),
|
|
41274
|
-
s: unionType([numberType().int(), stringType()]),
|
|
41275
|
-
yParity: numberType().int()
|
|
41276
|
-
});
|
|
41277
|
-
((SignedAuthorization$) => {
|
|
41278
|
-
SignedAuthorization$.inboundSchema = SignedAuthorization$inboundSchema;
|
|
41279
|
-
SignedAuthorization$.outboundSchema = SignedAuthorization$outboundSchema;
|
|
41280
|
-
})(SignedAuthorization$ ||= {});
|
|
41281
|
-
});
|
|
41282
|
-
|
|
41283
41430
|
// src/models/components/skybuyrequest.ts
|
|
41284
41431
|
var SkyBuyRequestTokenIn, SkyBuyRequestTokenIn$inboundSchema, SkyBuyRequestTokenIn$outboundSchema, SkyBuyRequestTokenIn$, SkyBuyRequestAmount$inboundSchema, SkyBuyRequestAmount$outboundSchema, SkyBuyRequestAmount$, SkyBuyRequest$inboundSchema, SkyBuyRequest$outboundSchema, SkyBuyRequest$;
|
|
41285
41432
|
var init_skybuyrequest = __esm(() => {
|
|
@@ -42331,6 +42478,7 @@ var init_components = __esm(() => {
|
|
|
42331
42478
|
init_aaveborrowrequest();
|
|
42332
42479
|
init_aavehistoricaltransactionsresponse();
|
|
42333
42480
|
init_aaveliquiditychangeresponse();
|
|
42481
|
+
init_aavelooprequest();
|
|
42334
42482
|
init_aaverateresponse();
|
|
42335
42483
|
init_aaverepayparams();
|
|
42336
42484
|
init_aaverepayrequest();
|
|
@@ -42416,6 +42564,9 @@ var init_components = __esm(() => {
|
|
|
42416
42564
|
init_morphowithdrawparams();
|
|
42417
42565
|
init_morphowithdrawrequest();
|
|
42418
42566
|
init_movement10percent();
|
|
42567
|
+
init_multicallauthorizationrequest();
|
|
42568
|
+
init_multicallauthorizationresponse();
|
|
42569
|
+
init_multicallexecuterequest();
|
|
42419
42570
|
init_openposition();
|
|
42420
42571
|
init_pendleaddliquidityparams();
|
|
42421
42572
|
init_pendleaddliquidityrequest();
|
|
@@ -50963,18 +51114,18 @@ Sends native ETH or ERC20 tokens from the sender's address to another address.`,
|
|
|
50963
51114
|
};
|
|
50964
51115
|
});
|
|
50965
51116
|
|
|
50966
|
-
// src/funcs/
|
|
50967
|
-
function
|
|
51117
|
+
// src/funcs/transactionBatchingAaveLoop.ts
|
|
51118
|
+
function transactionBatchingAaveLoop(client, request, options) {
|
|
50968
51119
|
return new APIPromise($do56(client, request, options));
|
|
50969
51120
|
}
|
|
50970
51121
|
async function $do56(client, request, options) {
|
|
50971
|
-
const parsed = safeParse(request, (value) =>
|
|
51122
|
+
const parsed = safeParse(request, (value) => AaveLoopRequest$outboundSchema.parse(value), "Input validation failed");
|
|
50972
51123
|
if (!parsed.ok) {
|
|
50973
51124
|
return [parsed, { status: "invalid" }];
|
|
50974
51125
|
}
|
|
50975
51126
|
const payload = parsed.value;
|
|
50976
51127
|
const body = encodeJSON("body", payload, { explode: true });
|
|
50977
|
-
const path = pathToFunc("/v0/
|
|
51128
|
+
const path = pathToFunc("/v0/multicall/aave/loop")();
|
|
50978
51129
|
const headers = new Headers(compactMap({
|
|
50979
51130
|
"Content-Type": "application/json",
|
|
50980
51131
|
Accept: "application/json"
|
|
@@ -50985,7 +51136,7 @@ async function $do56(client, request, options) {
|
|
|
50985
51136
|
const context = {
|
|
50986
51137
|
options: client._options,
|
|
50987
51138
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
50988
|
-
operationID: "
|
|
51139
|
+
operationID: "multicall_aave_loop",
|
|
50989
51140
|
oAuth2Scopes: [],
|
|
50990
51141
|
resolvedSecurity: requestSecurity,
|
|
50991
51142
|
securitySource: client._options.apiKeyAuth,
|
|
@@ -51019,13 +51170,13 @@ async function $do56(client, request, options) {
|
|
|
51019
51170
|
const responseFields = {
|
|
51020
51171
|
HttpMeta: { Response: response, Request: req }
|
|
51021
51172
|
};
|
|
51022
|
-
const [result] = await match(json(200,
|
|
51173
|
+
const [result] = await match(json(200, UnsignedMulticallTransaction$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51023
51174
|
if (!result.ok) {
|
|
51024
51175
|
return [result, { status: "complete", request: req, response }];
|
|
51025
51176
|
}
|
|
51026
51177
|
return [result, { status: "complete", request: req, response }];
|
|
51027
51178
|
}
|
|
51028
|
-
var
|
|
51179
|
+
var init_transactionBatchingAaveLoop = __esm(() => {
|
|
51029
51180
|
init_encodings();
|
|
51030
51181
|
init_matchers();
|
|
51031
51182
|
init_primitives();
|
|
@@ -51037,31 +51188,33 @@ var init_uniswapV3LiquidityProvisionIncrease = __esm(() => {
|
|
|
51037
51188
|
init_async();
|
|
51038
51189
|
});
|
|
51039
51190
|
|
|
51040
|
-
// src/mcp-server/tools/
|
|
51041
|
-
var args56, tool$
|
|
51042
|
-
var
|
|
51043
|
-
|
|
51191
|
+
// src/mcp-server/tools/transactionBatchingAaveLoop.ts
|
|
51192
|
+
var args56, tool$transactionBatchingAaveLoop;
|
|
51193
|
+
var init_transactionBatchingAaveLoop2 = __esm(() => {
|
|
51194
|
+
init_transactionBatchingAaveLoop();
|
|
51044
51195
|
init_components();
|
|
51045
51196
|
init_tools();
|
|
51046
51197
|
args56 = {
|
|
51047
|
-
request:
|
|
51198
|
+
request: AaveLoopRequest$inboundSchema
|
|
51048
51199
|
};
|
|
51049
|
-
tool$
|
|
51050
|
-
name: "
|
|
51051
|
-
description: `
|
|
51200
|
+
tool$transactionBatchingAaveLoop = {
|
|
51201
|
+
name: "transaction-batching-aave-loop",
|
|
51202
|
+
description: `AAVE leverage long/short
|
|
51052
51203
|
|
|
51053
|
-
|
|
51054
|
-
|
|
51204
|
+
Execute an Aave looping strategy that involves repeated supply and borrow
|
|
51205
|
+
operations.
|
|
51055
51206
|
|
|
51056
|
-
|
|
51057
|
-
|
|
51058
|
-
|
|
51059
|
-
|
|
51060
|
-
|
|
51061
|
-
|
|
51207
|
+
This endpoint creates a multicall transaction that performs a series of operations:
|
|
51208
|
+
1. Approves and supplies initial token
|
|
51209
|
+
2. For each loop:
|
|
51210
|
+
- Borrows another token
|
|
51211
|
+
- Swaps borrowed token back to supply token
|
|
51212
|
+
- Supplies the swapped tokens
|
|
51213
|
+
|
|
51214
|
+
The transaction must be authorized using the /authorization endpoint to prevent replay attacks.`,
|
|
51062
51215
|
args: args56,
|
|
51063
51216
|
tool: async (client, args57, ctx) => {
|
|
51064
|
-
const [result, apiCall] = await
|
|
51217
|
+
const [result, apiCall] = await transactionBatchingAaveLoop(client, args57.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51065
51218
|
if (!result.ok) {
|
|
51066
51219
|
return {
|
|
51067
51220
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51074,23 +51227,20 @@ process.`,
|
|
|
51074
51227
|
};
|
|
51075
51228
|
});
|
|
51076
51229
|
|
|
51077
|
-
// src/funcs/
|
|
51078
|
-
function
|
|
51230
|
+
// src/funcs/transactionBatchingAuthorization.ts
|
|
51231
|
+
function transactionBatchingAuthorization(client, request, options) {
|
|
51079
51232
|
return new APIPromise($do57(client, request, options));
|
|
51080
51233
|
}
|
|
51081
51234
|
async function $do57(client, request, options) {
|
|
51082
|
-
const parsed = safeParse(request, (value) =>
|
|
51235
|
+
const parsed = safeParse(request, (value) => MulticallAuthorizationRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51083
51236
|
if (!parsed.ok) {
|
|
51084
51237
|
return [parsed, { status: "invalid" }];
|
|
51085
51238
|
}
|
|
51086
51239
|
const payload = parsed.value;
|
|
51087
|
-
const body =
|
|
51088
|
-
const path = pathToFunc("/v0/
|
|
51089
|
-
const query = encodeFormQuery({
|
|
51090
|
-
chain: payload.chain,
|
|
51091
|
-
token_id: payload.token_id
|
|
51092
|
-
});
|
|
51240
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
51241
|
+
const path = pathToFunc("/v0/multicall/authorization")();
|
|
51093
51242
|
const headers = new Headers(compactMap({
|
|
51243
|
+
"Content-Type": "application/json",
|
|
51094
51244
|
Accept: "application/json"
|
|
51095
51245
|
}));
|
|
51096
51246
|
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
@@ -51099,7 +51249,7 @@ async function $do57(client, request, options) {
|
|
|
51099
51249
|
const context = {
|
|
51100
51250
|
options: client._options,
|
|
51101
51251
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51102
|
-
operationID: "
|
|
51252
|
+
operationID: "multicall_authorization",
|
|
51103
51253
|
oAuth2Scopes: [],
|
|
51104
51254
|
resolvedSecurity: requestSecurity,
|
|
51105
51255
|
securitySource: client._options.apiKeyAuth,
|
|
@@ -51108,11 +51258,10 @@ async function $do57(client, request, options) {
|
|
|
51108
51258
|
};
|
|
51109
51259
|
const requestRes = client._createRequest(context, {
|
|
51110
51260
|
security: requestSecurity,
|
|
51111
|
-
method: "
|
|
51261
|
+
method: "POST",
|
|
51112
51262
|
baseURL: options?.serverURL,
|
|
51113
51263
|
path,
|
|
51114
51264
|
headers,
|
|
51115
|
-
query,
|
|
51116
51265
|
body,
|
|
51117
51266
|
userAgent: client._options.userAgent,
|
|
51118
51267
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
|
|
@@ -51134,13 +51283,13 @@ async function $do57(client, request, options) {
|
|
|
51134
51283
|
const responseFields = {
|
|
51135
51284
|
HttpMeta: { Response: response, Request: req }
|
|
51136
51285
|
};
|
|
51137
|
-
const [result] = await match(json(200,
|
|
51286
|
+
const [result] = await match(json(200, MulticallAuthorizationResponse$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51138
51287
|
if (!result.ok) {
|
|
51139
51288
|
return [result, { status: "complete", request: req, response }];
|
|
51140
51289
|
}
|
|
51141
51290
|
return [result, { status: "complete", request: req, response }];
|
|
51142
51291
|
}
|
|
51143
|
-
var
|
|
51292
|
+
var init_transactionBatchingAuthorization = __esm(() => {
|
|
51144
51293
|
init_encodings();
|
|
51145
51294
|
init_matchers();
|
|
51146
51295
|
init_primitives();
|
|
@@ -51149,34 +51298,31 @@ var init_uniswapV3LiquidityProvisionInRange = __esm(() => {
|
|
|
51149
51298
|
init_url();
|
|
51150
51299
|
init_components();
|
|
51151
51300
|
init_errors2();
|
|
51152
|
-
init_operations();
|
|
51153
51301
|
init_async();
|
|
51154
51302
|
});
|
|
51155
51303
|
|
|
51156
|
-
// src/mcp-server/tools/
|
|
51157
|
-
var args57, tool$
|
|
51158
|
-
var
|
|
51159
|
-
|
|
51160
|
-
|
|
51304
|
+
// src/mcp-server/tools/transactionBatchingAuthorization.ts
|
|
51305
|
+
var args57, tool$transactionBatchingAuthorization;
|
|
51306
|
+
var init_transactionBatchingAuthorization2 = __esm(() => {
|
|
51307
|
+
init_transactionBatchingAuthorization();
|
|
51308
|
+
init_components();
|
|
51161
51309
|
init_tools();
|
|
51162
51310
|
args57 = {
|
|
51163
|
-
request:
|
|
51311
|
+
request: MulticallAuthorizationRequest$inboundSchema
|
|
51164
51312
|
};
|
|
51165
|
-
tool$
|
|
51166
|
-
name: "
|
|
51167
|
-
description: `
|
|
51313
|
+
tool$transactionBatchingAuthorization = {
|
|
51314
|
+
name: "transaction-batching-authorization",
|
|
51315
|
+
description: `Enable transaction bundling.
|
|
51168
51316
|
|
|
51169
|
-
|
|
51170
|
-
position is within the active tick range on the uniswap platform.
|
|
51317
|
+
Get authorization for bundling transactions.
|
|
51171
51318
|
|
|
51172
|
-
|
|
51173
|
-
|
|
51174
|
-
|
|
51175
|
-
|
|
51176
|
-
and earning trading fees.`,
|
|
51319
|
+
Currently this is required for every transaction bundle to prevent replay attacks
|
|
51320
|
+
and ensure transaction ordering when batching multiple actions into a single
|
|
51321
|
+
transaction. The authorization includes a nonce and chain ID to guarantee
|
|
51322
|
+
transaction uniqueness and proper network targeting.`,
|
|
51177
51323
|
args: args57,
|
|
51178
51324
|
tool: async (client, args58, ctx) => {
|
|
51179
|
-
const [result, apiCall] = await
|
|
51325
|
+
const [result, apiCall] = await transactionBatchingAuthorization(client, args58.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51180
51326
|
if (!result.ok) {
|
|
51181
51327
|
return {
|
|
51182
51328
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51189,18 +51335,18 @@ and earning trading fees.`,
|
|
|
51189
51335
|
};
|
|
51190
51336
|
});
|
|
51191
51337
|
|
|
51192
|
-
// src/funcs/
|
|
51193
|
-
function
|
|
51338
|
+
// src/funcs/transactionBatchingExecute.ts
|
|
51339
|
+
function transactionBatchingExecute(client, request, options) {
|
|
51194
51340
|
return new APIPromise($do58(client, request, options));
|
|
51195
51341
|
}
|
|
51196
51342
|
async function $do58(client, request, options) {
|
|
51197
|
-
const parsed = safeParse(request, (value) =>
|
|
51343
|
+
const parsed = safeParse(request, (value) => MulticallExecuteRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51198
51344
|
if (!parsed.ok) {
|
|
51199
51345
|
return [parsed, { status: "invalid" }];
|
|
51200
51346
|
}
|
|
51201
51347
|
const payload = parsed.value;
|
|
51202
51348
|
const body = encodeJSON("body", payload, { explode: true });
|
|
51203
|
-
const path = pathToFunc("/v0/
|
|
51349
|
+
const path = pathToFunc("/v0/multicall/execute")();
|
|
51204
51350
|
const headers = new Headers(compactMap({
|
|
51205
51351
|
"Content-Type": "application/json",
|
|
51206
51352
|
Accept: "application/json"
|
|
@@ -51211,7 +51357,7 @@ async function $do58(client, request, options) {
|
|
|
51211
51357
|
const context = {
|
|
51212
51358
|
options: client._options,
|
|
51213
51359
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51214
|
-
operationID: "
|
|
51360
|
+
operationID: "multicall_execute",
|
|
51215
51361
|
oAuth2Scopes: [],
|
|
51216
51362
|
resolvedSecurity: requestSecurity,
|
|
51217
51363
|
securitySource: client._options.apiKeyAuth,
|
|
@@ -51245,13 +51391,13 @@ async function $do58(client, request, options) {
|
|
|
51245
51391
|
const responseFields = {
|
|
51246
51392
|
HttpMeta: { Response: response, Request: req }
|
|
51247
51393
|
};
|
|
51248
|
-
const [result] = await match(json(200,
|
|
51394
|
+
const [result] = await match(json(200, UnsignedMulticallTransaction$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51249
51395
|
if (!result.ok) {
|
|
51250
51396
|
return [result, { status: "complete", request: req, response }];
|
|
51251
51397
|
}
|
|
51252
51398
|
return [result, { status: "complete", request: req, response }];
|
|
51253
51399
|
}
|
|
51254
|
-
var
|
|
51400
|
+
var init_transactionBatchingExecute = __esm(() => {
|
|
51255
51401
|
init_encodings();
|
|
51256
51402
|
init_matchers();
|
|
51257
51403
|
init_primitives();
|
|
@@ -51263,31 +51409,29 @@ var init_uniswapV3LiquidityProvisionMint = __esm(() => {
|
|
|
51263
51409
|
init_async();
|
|
51264
51410
|
});
|
|
51265
51411
|
|
|
51266
|
-
// src/mcp-server/tools/
|
|
51267
|
-
var args58, tool$
|
|
51268
|
-
var
|
|
51269
|
-
|
|
51412
|
+
// src/mcp-server/tools/transactionBatchingExecute.ts
|
|
51413
|
+
var args58, tool$transactionBatchingExecute;
|
|
51414
|
+
var init_transactionBatchingExecute2 = __esm(() => {
|
|
51415
|
+
init_transactionBatchingExecute();
|
|
51270
51416
|
init_components();
|
|
51271
51417
|
init_tools();
|
|
51272
51418
|
args58 = {
|
|
51273
|
-
request:
|
|
51419
|
+
request: MulticallExecuteRequest$inboundSchema
|
|
51274
51420
|
};
|
|
51275
|
-
tool$
|
|
51276
|
-
name: "
|
|
51277
|
-
description: `
|
|
51421
|
+
tool$transactionBatchingExecute = {
|
|
51422
|
+
name: "transaction-batching-execute",
|
|
51423
|
+
description: `Construct Bundled Transaction
|
|
51278
51424
|
|
|
51279
|
-
|
|
51280
|
-
|
|
51425
|
+
Bundle arbitrary transactions together into a single multicall transaction using
|
|
51426
|
+
EIP-7702.
|
|
51281
51427
|
|
|
51282
|
-
|
|
51283
|
-
|
|
51284
|
-
|
|
51285
|
-
|
|
51286
|
-
requires details such as the token pair, amount, and any additional parameters
|
|
51287
|
-
needed for the minting process.`,
|
|
51428
|
+
This endpoint allows bundling multiple contract calls into a single atomic
|
|
51429
|
+
transaction, reducing gas costs and ensuring all operations succeed or fail
|
|
51430
|
+
together. The transaction must be authorized using the /authorization endpoint to
|
|
51431
|
+
prevent replay attacks.`,
|
|
51288
51432
|
args: args58,
|
|
51289
51433
|
tool: async (client, args59, ctx) => {
|
|
51290
|
-
const [result, apiCall] = await
|
|
51434
|
+
const [result, apiCall] = await transactionBatchingExecute(client, args59.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51291
51435
|
if (!result.ok) {
|
|
51292
51436
|
return {
|
|
51293
51437
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51300,23 +51444,20 @@ needed for the minting process.`,
|
|
|
51300
51444
|
};
|
|
51301
51445
|
});
|
|
51302
51446
|
|
|
51303
|
-
// src/funcs/
|
|
51304
|
-
function
|
|
51447
|
+
// src/funcs/uniswapV3LiquidityProvisionIncrease.ts
|
|
51448
|
+
function uniswapV3LiquidityProvisionIncrease(client, request, options) {
|
|
51305
51449
|
return new APIPromise($do59(client, request, options));
|
|
51306
51450
|
}
|
|
51307
51451
|
async function $do59(client, request, options) {
|
|
51308
|
-
const parsed = safeParse(request, (value) =>
|
|
51452
|
+
const parsed = safeParse(request, (value) => UniswapIncreaseLiquidityProvisionRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51309
51453
|
if (!parsed.ok) {
|
|
51310
51454
|
return [parsed, { status: "invalid" }];
|
|
51311
51455
|
}
|
|
51312
51456
|
const payload = parsed.value;
|
|
51313
|
-
const body =
|
|
51314
|
-
const path = pathToFunc("/v0/uniswap/liquidity_provision/
|
|
51315
|
-
const query = encodeFormQuery({
|
|
51316
|
-
chain: payload.chain,
|
|
51317
|
-
user: payload.user
|
|
51318
|
-
});
|
|
51457
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
51458
|
+
const path = pathToFunc("/v0/uniswap/liquidity_provision/increase")();
|
|
51319
51459
|
const headers = new Headers(compactMap({
|
|
51460
|
+
"Content-Type": "application/json",
|
|
51320
51461
|
Accept: "application/json"
|
|
51321
51462
|
}));
|
|
51322
51463
|
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
@@ -51325,7 +51466,7 @@ async function $do59(client, request, options) {
|
|
|
51325
51466
|
const context = {
|
|
51326
51467
|
options: client._options,
|
|
51327
51468
|
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51328
|
-
operationID: "
|
|
51469
|
+
operationID: "uniswap_liquidity_provision_increase",
|
|
51329
51470
|
oAuth2Scopes: [],
|
|
51330
51471
|
resolvedSecurity: requestSecurity,
|
|
51331
51472
|
securitySource: client._options.apiKeyAuth,
|
|
@@ -51334,11 +51475,10 @@ async function $do59(client, request, options) {
|
|
|
51334
51475
|
};
|
|
51335
51476
|
const requestRes = client._createRequest(context, {
|
|
51336
51477
|
security: requestSecurity,
|
|
51337
|
-
method: "
|
|
51478
|
+
method: "POST",
|
|
51338
51479
|
baseURL: options?.serverURL,
|
|
51339
51480
|
path,
|
|
51340
51481
|
headers,
|
|
51341
|
-
query,
|
|
51342
51482
|
body,
|
|
51343
51483
|
userAgent: client._options.userAgent,
|
|
51344
51484
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
|
|
@@ -51360,13 +51500,13 @@ async function $do59(client, request, options) {
|
|
|
51360
51500
|
const responseFields = {
|
|
51361
51501
|
HttpMeta: { Response: response, Request: req }
|
|
51362
51502
|
};
|
|
51363
|
-
const [result] = await match(json(200,
|
|
51503
|
+
const [result] = await match(json(200, TxResponse$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51364
51504
|
if (!result.ok) {
|
|
51365
51505
|
return [result, { status: "complete", request: req, response }];
|
|
51366
51506
|
}
|
|
51367
51507
|
return [result, { status: "complete", request: req, response }];
|
|
51368
51508
|
}
|
|
51369
|
-
var
|
|
51509
|
+
var init_uniswapV3LiquidityProvisionIncrease = __esm(() => {
|
|
51370
51510
|
init_encodings();
|
|
51371
51511
|
init_matchers();
|
|
51372
51512
|
init_primitives();
|
|
@@ -51375,17 +51515,358 @@ var init_uniswapV3LiquidityProvisionPositions = __esm(() => {
|
|
|
51375
51515
|
init_url();
|
|
51376
51516
|
init_components();
|
|
51377
51517
|
init_errors2();
|
|
51378
|
-
init_operations();
|
|
51379
51518
|
init_async();
|
|
51380
51519
|
});
|
|
51381
51520
|
|
|
51382
|
-
// src/mcp-server/tools/
|
|
51383
|
-
var args59, tool$
|
|
51384
|
-
var
|
|
51385
|
-
|
|
51386
|
-
|
|
51387
|
-
init_tools();
|
|
51521
|
+
// src/mcp-server/tools/uniswapV3LiquidityProvisionIncrease.ts
|
|
51522
|
+
var args59, tool$uniswapV3LiquidityProvisionIncrease;
|
|
51523
|
+
var init_uniswapV3LiquidityProvisionIncrease2 = __esm(() => {
|
|
51524
|
+
init_uniswapV3LiquidityProvisionIncrease();
|
|
51525
|
+
init_components();
|
|
51526
|
+
init_tools();
|
|
51388
51527
|
args59 = {
|
|
51528
|
+
request: UniswapIncreaseLiquidityProvisionRequest$inboundSchema
|
|
51529
|
+
};
|
|
51530
|
+
tool$uniswapV3LiquidityProvisionIncrease = {
|
|
51531
|
+
name: "uniswap-v3-liquidity-provision-increase",
|
|
51532
|
+
description: `Increase an LP position
|
|
51533
|
+
|
|
51534
|
+
This endpoint allows users to increase their existing Liquidity Provider (LP)
|
|
51535
|
+
positions on the Uniswap platform.
|
|
51536
|
+
|
|
51537
|
+
By providing the necessary parameters, users can add more liquidity to their current
|
|
51538
|
+
positions, thereby increasing their stake in the liquidity pool. This operation is
|
|
51539
|
+
beneficial for users who wish to enhance their potential earnings from trading fees
|
|
51540
|
+
within the pool. The endpoint requires details such as the token pair, additional
|
|
51541
|
+
amount to be added, and any other parameters necessary for the liquidity increase
|
|
51542
|
+
process.`,
|
|
51543
|
+
args: args59,
|
|
51544
|
+
tool: async (client, args60, ctx) => {
|
|
51545
|
+
const [result, apiCall] = await uniswapV3LiquidityProvisionIncrease(client, args60.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51546
|
+
if (!result.ok) {
|
|
51547
|
+
return {
|
|
51548
|
+
content: [{ type: "text", text: result.error.message }],
|
|
51549
|
+
isError: true
|
|
51550
|
+
};
|
|
51551
|
+
}
|
|
51552
|
+
const value = result.value;
|
|
51553
|
+
return formatResult(value, apiCall);
|
|
51554
|
+
}
|
|
51555
|
+
};
|
|
51556
|
+
});
|
|
51557
|
+
|
|
51558
|
+
// src/funcs/uniswapV3LiquidityProvisionInRange.ts
|
|
51559
|
+
function uniswapV3LiquidityProvisionInRange(client, request, options) {
|
|
51560
|
+
return new APIPromise($do60(client, request, options));
|
|
51561
|
+
}
|
|
51562
|
+
async function $do60(client, request, options) {
|
|
51563
|
+
const parsed = safeParse(request, (value) => UniswapLiquidityProvisionInRangeRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51564
|
+
if (!parsed.ok) {
|
|
51565
|
+
return [parsed, { status: "invalid" }];
|
|
51566
|
+
}
|
|
51567
|
+
const payload = parsed.value;
|
|
51568
|
+
const body = null;
|
|
51569
|
+
const path = pathToFunc("/v0/uniswap/liquidity_provision/in_range/get")();
|
|
51570
|
+
const query = encodeFormQuery({
|
|
51571
|
+
chain: payload.chain,
|
|
51572
|
+
token_id: payload.token_id
|
|
51573
|
+
});
|
|
51574
|
+
const headers = new Headers(compactMap({
|
|
51575
|
+
Accept: "application/json"
|
|
51576
|
+
}));
|
|
51577
|
+
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
51578
|
+
const securityInput = secConfig == null ? {} : { apiKeyAuth: secConfig };
|
|
51579
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
51580
|
+
const context = {
|
|
51581
|
+
options: client._options,
|
|
51582
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51583
|
+
operationID: "uniswap_liquidity_provision_in_range",
|
|
51584
|
+
oAuth2Scopes: [],
|
|
51585
|
+
resolvedSecurity: requestSecurity,
|
|
51586
|
+
securitySource: client._options.apiKeyAuth,
|
|
51587
|
+
retryConfig: options?.retries || client._options.retryConfig || { strategy: "none" },
|
|
51588
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"]
|
|
51589
|
+
};
|
|
51590
|
+
const requestRes = client._createRequest(context, {
|
|
51591
|
+
security: requestSecurity,
|
|
51592
|
+
method: "GET",
|
|
51593
|
+
baseURL: options?.serverURL,
|
|
51594
|
+
path,
|
|
51595
|
+
headers,
|
|
51596
|
+
query,
|
|
51597
|
+
body,
|
|
51598
|
+
userAgent: client._options.userAgent,
|
|
51599
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
|
|
51600
|
+
}, options);
|
|
51601
|
+
if (!requestRes.ok) {
|
|
51602
|
+
return [requestRes, { status: "invalid" }];
|
|
51603
|
+
}
|
|
51604
|
+
const req = requestRes.value;
|
|
51605
|
+
const doResult = await client._do(req, {
|
|
51606
|
+
context,
|
|
51607
|
+
errorCodes: ["422", "4XX", "5XX"],
|
|
51608
|
+
retryConfig: context.retryConfig,
|
|
51609
|
+
retryCodes: context.retryCodes
|
|
51610
|
+
});
|
|
51611
|
+
if (!doResult.ok) {
|
|
51612
|
+
return [doResult, { status: "request-error", request: req }];
|
|
51613
|
+
}
|
|
51614
|
+
const response = doResult.value;
|
|
51615
|
+
const responseFields = {
|
|
51616
|
+
HttpMeta: { Response: response, Request: req }
|
|
51617
|
+
};
|
|
51618
|
+
const [result] = await match(json(200, UniswapCheckInRangeResponse$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51619
|
+
if (!result.ok) {
|
|
51620
|
+
return [result, { status: "complete", request: req, response }];
|
|
51621
|
+
}
|
|
51622
|
+
return [result, { status: "complete", request: req, response }];
|
|
51623
|
+
}
|
|
51624
|
+
var init_uniswapV3LiquidityProvisionInRange = __esm(() => {
|
|
51625
|
+
init_encodings();
|
|
51626
|
+
init_matchers();
|
|
51627
|
+
init_primitives();
|
|
51628
|
+
init_schemas();
|
|
51629
|
+
init_security();
|
|
51630
|
+
init_url();
|
|
51631
|
+
init_components();
|
|
51632
|
+
init_errors2();
|
|
51633
|
+
init_operations();
|
|
51634
|
+
init_async();
|
|
51635
|
+
});
|
|
51636
|
+
|
|
51637
|
+
// src/mcp-server/tools/uniswapV3LiquidityProvisionInRange.ts
|
|
51638
|
+
var args60, tool$uniswapV3LiquidityProvisionInRange;
|
|
51639
|
+
var init_uniswapV3LiquidityProvisionInRange2 = __esm(() => {
|
|
51640
|
+
init_uniswapV3LiquidityProvisionInRange();
|
|
51641
|
+
init_operations();
|
|
51642
|
+
init_tools();
|
|
51643
|
+
args60 = {
|
|
51644
|
+
request: UniswapLiquidityProvisionInRangeRequest$inboundSchema
|
|
51645
|
+
};
|
|
51646
|
+
tool$uniswapV3LiquidityProvisionInRange = {
|
|
51647
|
+
name: "uniswap-v3-liquidity-provision-in-range",
|
|
51648
|
+
description: `Check if LP is active.
|
|
51649
|
+
|
|
51650
|
+
This endpoint allows users to check whether a specific liquidity provider ()
|
|
51651
|
+
position is within the active tick range on the uniswap platform.
|
|
51652
|
+
|
|
51653
|
+
by providing the token id associated with the position, users can verify if the
|
|
51654
|
+
position is currently within the tick range where trading occurs. this information
|
|
51655
|
+
is essential for users to monitor the status of their lp positions and ensure that
|
|
51656
|
+
they are actively participating in the trading activities within the liquidity pool
|
|
51657
|
+
and earning trading fees.`,
|
|
51658
|
+
args: args60,
|
|
51659
|
+
tool: async (client, args61, ctx) => {
|
|
51660
|
+
const [result, apiCall] = await uniswapV3LiquidityProvisionInRange(client, args61.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51661
|
+
if (!result.ok) {
|
|
51662
|
+
return {
|
|
51663
|
+
content: [{ type: "text", text: result.error.message }],
|
|
51664
|
+
isError: true
|
|
51665
|
+
};
|
|
51666
|
+
}
|
|
51667
|
+
const value = result.value;
|
|
51668
|
+
return formatResult(value, apiCall);
|
|
51669
|
+
}
|
|
51670
|
+
};
|
|
51671
|
+
});
|
|
51672
|
+
|
|
51673
|
+
// src/funcs/uniswapV3LiquidityProvisionMint.ts
|
|
51674
|
+
function uniswapV3LiquidityProvisionMint(client, request, options) {
|
|
51675
|
+
return new APIPromise($do61(client, request, options));
|
|
51676
|
+
}
|
|
51677
|
+
async function $do61(client, request, options) {
|
|
51678
|
+
const parsed = safeParse(request, (value) => UniswapMintLiquidityProvisionRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51679
|
+
if (!parsed.ok) {
|
|
51680
|
+
return [parsed, { status: "invalid" }];
|
|
51681
|
+
}
|
|
51682
|
+
const payload = parsed.value;
|
|
51683
|
+
const body = encodeJSON("body", payload, { explode: true });
|
|
51684
|
+
const path = pathToFunc("/v0/uniswap/liquidity_provision/mint")();
|
|
51685
|
+
const headers = new Headers(compactMap({
|
|
51686
|
+
"Content-Type": "application/json",
|
|
51687
|
+
Accept: "application/json"
|
|
51688
|
+
}));
|
|
51689
|
+
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
51690
|
+
const securityInput = secConfig == null ? {} : { apiKeyAuth: secConfig };
|
|
51691
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
51692
|
+
const context = {
|
|
51693
|
+
options: client._options,
|
|
51694
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51695
|
+
operationID: "uniswap_liquidity_provision_mint",
|
|
51696
|
+
oAuth2Scopes: [],
|
|
51697
|
+
resolvedSecurity: requestSecurity,
|
|
51698
|
+
securitySource: client._options.apiKeyAuth,
|
|
51699
|
+
retryConfig: options?.retries || client._options.retryConfig || { strategy: "none" },
|
|
51700
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"]
|
|
51701
|
+
};
|
|
51702
|
+
const requestRes = client._createRequest(context, {
|
|
51703
|
+
security: requestSecurity,
|
|
51704
|
+
method: "POST",
|
|
51705
|
+
baseURL: options?.serverURL,
|
|
51706
|
+
path,
|
|
51707
|
+
headers,
|
|
51708
|
+
body,
|
|
51709
|
+
userAgent: client._options.userAgent,
|
|
51710
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
|
|
51711
|
+
}, options);
|
|
51712
|
+
if (!requestRes.ok) {
|
|
51713
|
+
return [requestRes, { status: "invalid" }];
|
|
51714
|
+
}
|
|
51715
|
+
const req = requestRes.value;
|
|
51716
|
+
const doResult = await client._do(req, {
|
|
51717
|
+
context,
|
|
51718
|
+
errorCodes: ["422", "4XX", "5XX"],
|
|
51719
|
+
retryConfig: context.retryConfig,
|
|
51720
|
+
retryCodes: context.retryCodes
|
|
51721
|
+
});
|
|
51722
|
+
if (!doResult.ok) {
|
|
51723
|
+
return [doResult, { status: "request-error", request: req }];
|
|
51724
|
+
}
|
|
51725
|
+
const response = doResult.value;
|
|
51726
|
+
const responseFields = {
|
|
51727
|
+
HttpMeta: { Response: response, Request: req }
|
|
51728
|
+
};
|
|
51729
|
+
const [result] = await match(json(200, TxResponse$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51730
|
+
if (!result.ok) {
|
|
51731
|
+
return [result, { status: "complete", request: req, response }];
|
|
51732
|
+
}
|
|
51733
|
+
return [result, { status: "complete", request: req, response }];
|
|
51734
|
+
}
|
|
51735
|
+
var init_uniswapV3LiquidityProvisionMint = __esm(() => {
|
|
51736
|
+
init_encodings();
|
|
51737
|
+
init_matchers();
|
|
51738
|
+
init_primitives();
|
|
51739
|
+
init_schemas();
|
|
51740
|
+
init_security();
|
|
51741
|
+
init_url();
|
|
51742
|
+
init_components();
|
|
51743
|
+
init_errors2();
|
|
51744
|
+
init_async();
|
|
51745
|
+
});
|
|
51746
|
+
|
|
51747
|
+
// src/mcp-server/tools/uniswapV3LiquidityProvisionMint.ts
|
|
51748
|
+
var args61, tool$uniswapV3LiquidityProvisionMint;
|
|
51749
|
+
var init_uniswapV3LiquidityProvisionMint2 = __esm(() => {
|
|
51750
|
+
init_uniswapV3LiquidityProvisionMint();
|
|
51751
|
+
init_components();
|
|
51752
|
+
init_tools();
|
|
51753
|
+
args61 = {
|
|
51754
|
+
request: UniswapMintLiquidityProvisionRequest$inboundSchema
|
|
51755
|
+
};
|
|
51756
|
+
tool$uniswapV3LiquidityProvisionMint = {
|
|
51757
|
+
name: "uniswap-v3-liquidity-provision-mint",
|
|
51758
|
+
description: `Open a new LP position
|
|
51759
|
+
|
|
51760
|
+
This endpoint allows users to open a new Liquidity Provider (LP) position on the
|
|
51761
|
+
Uniswap platform.
|
|
51762
|
+
|
|
51763
|
+
By providing the necessary parameters, users can initiate a minting process to
|
|
51764
|
+
create a new LP token, which represents their stake in a specific liquidity pool.
|
|
51765
|
+
This operation is essential for users looking to participate in liquidity provision,
|
|
51766
|
+
enabling them to earn fees from trades that occur within the pool. The endpoint
|
|
51767
|
+
requires details such as the token pair, amount, and any additional parameters
|
|
51768
|
+
needed for the minting process.`,
|
|
51769
|
+
args: args61,
|
|
51770
|
+
tool: async (client, args62, ctx) => {
|
|
51771
|
+
const [result, apiCall] = await uniswapV3LiquidityProvisionMint(client, args62.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51772
|
+
if (!result.ok) {
|
|
51773
|
+
return {
|
|
51774
|
+
content: [{ type: "text", text: result.error.message }],
|
|
51775
|
+
isError: true
|
|
51776
|
+
};
|
|
51777
|
+
}
|
|
51778
|
+
const value = result.value;
|
|
51779
|
+
return formatResult(value, apiCall);
|
|
51780
|
+
}
|
|
51781
|
+
};
|
|
51782
|
+
});
|
|
51783
|
+
|
|
51784
|
+
// src/funcs/uniswapV3LiquidityProvisionPositions.ts
|
|
51785
|
+
function uniswapV3LiquidityProvisionPositions(client, request, options) {
|
|
51786
|
+
return new APIPromise($do62(client, request, options));
|
|
51787
|
+
}
|
|
51788
|
+
async function $do62(client, request, options) {
|
|
51789
|
+
const parsed = safeParse(request, (value) => UniswapLiquidityProvisionPositionsRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51790
|
+
if (!parsed.ok) {
|
|
51791
|
+
return [parsed, { status: "invalid" }];
|
|
51792
|
+
}
|
|
51793
|
+
const payload = parsed.value;
|
|
51794
|
+
const body = null;
|
|
51795
|
+
const path = pathToFunc("/v0/uniswap/liquidity_provision/positions/get")();
|
|
51796
|
+
const query = encodeFormQuery({
|
|
51797
|
+
chain: payload.chain,
|
|
51798
|
+
user: payload.user
|
|
51799
|
+
});
|
|
51800
|
+
const headers = new Headers(compactMap({
|
|
51801
|
+
Accept: "application/json"
|
|
51802
|
+
}));
|
|
51803
|
+
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
51804
|
+
const securityInput = secConfig == null ? {} : { apiKeyAuth: secConfig };
|
|
51805
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
51806
|
+
const context = {
|
|
51807
|
+
options: client._options,
|
|
51808
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
51809
|
+
operationID: "uniswap_liquidity_provision_positions",
|
|
51810
|
+
oAuth2Scopes: [],
|
|
51811
|
+
resolvedSecurity: requestSecurity,
|
|
51812
|
+
securitySource: client._options.apiKeyAuth,
|
|
51813
|
+
retryConfig: options?.retries || client._options.retryConfig || { strategy: "none" },
|
|
51814
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"]
|
|
51815
|
+
};
|
|
51816
|
+
const requestRes = client._createRequest(context, {
|
|
51817
|
+
security: requestSecurity,
|
|
51818
|
+
method: "GET",
|
|
51819
|
+
baseURL: options?.serverURL,
|
|
51820
|
+
path,
|
|
51821
|
+
headers,
|
|
51822
|
+
query,
|
|
51823
|
+
body,
|
|
51824
|
+
userAgent: client._options.userAgent,
|
|
51825
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
|
|
51826
|
+
}, options);
|
|
51827
|
+
if (!requestRes.ok) {
|
|
51828
|
+
return [requestRes, { status: "invalid" }];
|
|
51829
|
+
}
|
|
51830
|
+
const req = requestRes.value;
|
|
51831
|
+
const doResult = await client._do(req, {
|
|
51832
|
+
context,
|
|
51833
|
+
errorCodes: ["422", "4XX", "5XX"],
|
|
51834
|
+
retryConfig: context.retryConfig,
|
|
51835
|
+
retryCodes: context.retryCodes
|
|
51836
|
+
});
|
|
51837
|
+
if (!doResult.ok) {
|
|
51838
|
+
return [doResult, { status: "request-error", request: req }];
|
|
51839
|
+
}
|
|
51840
|
+
const response = doResult.value;
|
|
51841
|
+
const responseFields = {
|
|
51842
|
+
HttpMeta: { Response: response, Request: req }
|
|
51843
|
+
};
|
|
51844
|
+
const [result] = await match(json(200, UniswapLPPositionsInfoResponse$inboundSchema), jsonErr(422, HTTPValidationError$inboundSchema), fail("4XX"), fail("5XX"))(response, req, { extraFields: responseFields });
|
|
51845
|
+
if (!result.ok) {
|
|
51846
|
+
return [result, { status: "complete", request: req, response }];
|
|
51847
|
+
}
|
|
51848
|
+
return [result, { status: "complete", request: req, response }];
|
|
51849
|
+
}
|
|
51850
|
+
var init_uniswapV3LiquidityProvisionPositions = __esm(() => {
|
|
51851
|
+
init_encodings();
|
|
51852
|
+
init_matchers();
|
|
51853
|
+
init_primitives();
|
|
51854
|
+
init_schemas();
|
|
51855
|
+
init_security();
|
|
51856
|
+
init_url();
|
|
51857
|
+
init_components();
|
|
51858
|
+
init_errors2();
|
|
51859
|
+
init_operations();
|
|
51860
|
+
init_async();
|
|
51861
|
+
});
|
|
51862
|
+
|
|
51863
|
+
// src/mcp-server/tools/uniswapV3LiquidityProvisionPositions.ts
|
|
51864
|
+
var args62, tool$uniswapV3LiquidityProvisionPositions;
|
|
51865
|
+
var init_uniswapV3LiquidityProvisionPositions2 = __esm(() => {
|
|
51866
|
+
init_uniswapV3LiquidityProvisionPositions();
|
|
51867
|
+
init_operations();
|
|
51868
|
+
init_tools();
|
|
51869
|
+
args62 = {
|
|
51389
51870
|
request: UniswapLiquidityProvisionPositionsRequest$inboundSchema
|
|
51390
51871
|
};
|
|
51391
51872
|
tool$uniswapV3LiquidityProvisionPositions = {
|
|
@@ -51399,9 +51880,9 @@ Users can query this endpoint to obtain detailed information about their LP
|
|
|
51399
51880
|
positions, including the total number of positions and relevant metadata. This
|
|
51400
51881
|
information is crucial for users to manage and analyze their liquidity provision
|
|
51401
51882
|
activities effectively.`,
|
|
51402
|
-
args:
|
|
51403
|
-
tool: async (client,
|
|
51404
|
-
const [result, apiCall] = await uniswapV3LiquidityProvisionPositions(client,
|
|
51883
|
+
args: args62,
|
|
51884
|
+
tool: async (client, args63, ctx) => {
|
|
51885
|
+
const [result, apiCall] = await uniswapV3LiquidityProvisionPositions(client, args63.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51405
51886
|
if (!result.ok) {
|
|
51406
51887
|
return {
|
|
51407
51888
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51416,9 +51897,9 @@ activities effectively.`,
|
|
|
51416
51897
|
|
|
51417
51898
|
// src/funcs/uniswapV3LiquidityProvisionWithdraw.ts
|
|
51418
51899
|
function uniswapV3LiquidityProvisionWithdraw(client, request, options) {
|
|
51419
|
-
return new APIPromise($
|
|
51900
|
+
return new APIPromise($do63(client, request, options));
|
|
51420
51901
|
}
|
|
51421
|
-
async function $
|
|
51902
|
+
async function $do63(client, request, options) {
|
|
51422
51903
|
const parsed = safeParse(request, (value) => UniswapWithdrawLiquidityProvisionRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51423
51904
|
if (!parsed.ok) {
|
|
51424
51905
|
return [parsed, { status: "invalid" }];
|
|
@@ -51489,12 +51970,12 @@ var init_uniswapV3LiquidityProvisionWithdraw = __esm(() => {
|
|
|
51489
51970
|
});
|
|
51490
51971
|
|
|
51491
51972
|
// src/mcp-server/tools/uniswapV3LiquidityProvisionWithdraw.ts
|
|
51492
|
-
var
|
|
51973
|
+
var args63, tool$uniswapV3LiquidityProvisionWithdraw;
|
|
51493
51974
|
var init_uniswapV3LiquidityProvisionWithdraw2 = __esm(() => {
|
|
51494
51975
|
init_uniswapV3LiquidityProvisionWithdraw();
|
|
51495
51976
|
init_components();
|
|
51496
51977
|
init_tools();
|
|
51497
|
-
|
|
51978
|
+
args63 = {
|
|
51498
51979
|
request: UniswapWithdrawLiquidityProvisionRequest$inboundSchema
|
|
51499
51980
|
};
|
|
51500
51981
|
tool$uniswapV3LiquidityProvisionWithdraw = {
|
|
@@ -51511,9 +51992,9 @@ pools or investments. The endpoint requires details such as the token pair, the
|
|
|
51511
51992
|
amount to be withdrawn, and any additional parameters needed for the withdrawal
|
|
51512
51993
|
process. Users should ensure they meet any protocol requirements or conditions
|
|
51513
51994
|
before initiating a withdrawal to avoid potential issues or penalties.`,
|
|
51514
|
-
args:
|
|
51515
|
-
tool: async (client,
|
|
51516
|
-
const [result, apiCall] = await uniswapV3LiquidityProvisionWithdraw(client,
|
|
51995
|
+
args: args63,
|
|
51996
|
+
tool: async (client, args64, ctx) => {
|
|
51997
|
+
const [result, apiCall] = await uniswapV3LiquidityProvisionWithdraw(client, args64.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51517
51998
|
if (!result.ok) {
|
|
51518
51999
|
return {
|
|
51519
52000
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51528,9 +52009,9 @@ before initiating a withdrawal to avoid potential issues or penalties.`,
|
|
|
51528
52009
|
|
|
51529
52010
|
// src/funcs/uniswapV3PoolPrice.ts
|
|
51530
52011
|
function uniswapV3PoolPrice(client, request, options) {
|
|
51531
|
-
return new APIPromise($
|
|
52012
|
+
return new APIPromise($do64(client, request, options));
|
|
51532
52013
|
}
|
|
51533
|
-
async function $
|
|
52014
|
+
async function $do64(client, request, options) {
|
|
51534
52015
|
const parsed = safeParse(request, (value) => UniswapPoolPriceRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51535
52016
|
if (!parsed.ok) {
|
|
51536
52017
|
return [parsed, { status: "invalid" }];
|
|
@@ -51608,12 +52089,12 @@ var init_uniswapV3PoolPrice = __esm(() => {
|
|
|
51608
52089
|
});
|
|
51609
52090
|
|
|
51610
52091
|
// src/mcp-server/tools/uniswapV3PoolPrice.ts
|
|
51611
|
-
var
|
|
52092
|
+
var args64, tool$uniswapV3PoolPrice;
|
|
51612
52093
|
var init_uniswapV3PoolPrice2 = __esm(() => {
|
|
51613
52094
|
init_uniswapV3PoolPrice();
|
|
51614
52095
|
init_operations();
|
|
51615
52096
|
init_tools();
|
|
51616
|
-
|
|
52097
|
+
args64 = {
|
|
51617
52098
|
request: UniswapPoolPriceRequest$inboundSchema
|
|
51618
52099
|
};
|
|
51619
52100
|
tool$uniswapV3PoolPrice = {
|
|
@@ -51623,9 +52104,9 @@ var init_uniswapV3PoolPrice2 = __esm(() => {
|
|
|
51623
52104
|
This endpoint calculates the price of a token in a Uniswap pool.
|
|
51624
52105
|
|
|
51625
52106
|
The price is calculated based on the current pool state and the specified fee tier.`,
|
|
51626
|
-
args:
|
|
51627
|
-
tool: async (client,
|
|
51628
|
-
const [result, apiCall] = await uniswapV3PoolPrice(client,
|
|
52107
|
+
args: args64,
|
|
52108
|
+
tool: async (client, args65, ctx) => {
|
|
52109
|
+
const [result, apiCall] = await uniswapV3PoolPrice(client, args65.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51629
52110
|
if (!result.ok) {
|
|
51630
52111
|
return {
|
|
51631
52112
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51640,9 +52121,9 @@ The price is calculated based on the current pool state and the specified fee ti
|
|
|
51640
52121
|
|
|
51641
52122
|
// src/funcs/uniswapV3QuoteBuyExactly.ts
|
|
51642
52123
|
function uniswapV3QuoteBuyExactly(client, request, options) {
|
|
51643
|
-
return new APIPromise($
|
|
52124
|
+
return new APIPromise($do65(client, request, options));
|
|
51644
52125
|
}
|
|
51645
|
-
async function $
|
|
52126
|
+
async function $do65(client, request, options) {
|
|
51646
52127
|
const parsed = safeParse(request, (value) => UniswapQuoteBuyExactlyRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51647
52128
|
if (!parsed.ok) {
|
|
51648
52129
|
return [parsed, { status: "invalid" }];
|
|
@@ -51721,12 +52202,12 @@ var init_uniswapV3QuoteBuyExactly = __esm(() => {
|
|
|
51721
52202
|
});
|
|
51722
52203
|
|
|
51723
52204
|
// src/mcp-server/tools/uniswapV3QuoteBuyExactly.ts
|
|
51724
|
-
var
|
|
52205
|
+
var args65, tool$uniswapV3QuoteBuyExactly;
|
|
51725
52206
|
var init_uniswapV3QuoteBuyExactly2 = __esm(() => {
|
|
51726
52207
|
init_uniswapV3QuoteBuyExactly();
|
|
51727
52208
|
init_operations();
|
|
51728
52209
|
init_tools();
|
|
51729
|
-
|
|
52210
|
+
args65 = {
|
|
51730
52211
|
request: UniswapQuoteBuyExactlyRequest$inboundSchema
|
|
51731
52212
|
};
|
|
51732
52213
|
tool$uniswapV3QuoteBuyExactly = {
|
|
@@ -51738,9 +52219,9 @@ specified amount of output tokens from a Uniswap pool.
|
|
|
51738
52219
|
|
|
51739
52220
|
It also provides the resulting price after the transaction. The calculation takes
|
|
51740
52221
|
into account the current pool state and the specified fee tier.`,
|
|
51741
|
-
args:
|
|
51742
|
-
tool: async (client,
|
|
51743
|
-
const [result, apiCall] = await uniswapV3QuoteBuyExactly(client,
|
|
52222
|
+
args: args65,
|
|
52223
|
+
tool: async (client, args66, ctx) => {
|
|
52224
|
+
const [result, apiCall] = await uniswapV3QuoteBuyExactly(client, args66.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51744
52225
|
if (!result.ok) {
|
|
51745
52226
|
return {
|
|
51746
52227
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51755,9 +52236,9 @@ into account the current pool state and the specified fee tier.`,
|
|
|
51755
52236
|
|
|
51756
52237
|
// src/funcs/uniswapV3QuoteSellExactly.ts
|
|
51757
52238
|
function uniswapV3QuoteSellExactly(client, request, options) {
|
|
51758
|
-
return new APIPromise($
|
|
52239
|
+
return new APIPromise($do66(client, request, options));
|
|
51759
52240
|
}
|
|
51760
|
-
async function $
|
|
52241
|
+
async function $do66(client, request, options) {
|
|
51761
52242
|
const parsed = safeParse(request, (value) => UniswapQuoteSellExactlyRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51762
52243
|
if (!parsed.ok) {
|
|
51763
52244
|
return [parsed, { status: "invalid" }];
|
|
@@ -51836,12 +52317,12 @@ var init_uniswapV3QuoteSellExactly = __esm(() => {
|
|
|
51836
52317
|
});
|
|
51837
52318
|
|
|
51838
52319
|
// src/mcp-server/tools/uniswapV3QuoteSellExactly.ts
|
|
51839
|
-
var
|
|
52320
|
+
var args66, tool$uniswapV3QuoteSellExactly;
|
|
51840
52321
|
var init_uniswapV3QuoteSellExactly2 = __esm(() => {
|
|
51841
52322
|
init_uniswapV3QuoteSellExactly();
|
|
51842
52323
|
init_operations();
|
|
51843
52324
|
init_tools();
|
|
51844
|
-
|
|
52325
|
+
args66 = {
|
|
51845
52326
|
request: UniswapQuoteSellExactlyRequest$inboundSchema
|
|
51846
52327
|
};
|
|
51847
52328
|
tool$uniswapV3QuoteSellExactly = {
|
|
@@ -51853,9 +52334,9 @@ specified amount of output tokens from a Uniswap pool.
|
|
|
51853
52334
|
|
|
51854
52335
|
It also provides the resulting price after the transaction. The calculation takes
|
|
51855
52336
|
into account the current pool state and the specified fee tier.`,
|
|
51856
|
-
args:
|
|
51857
|
-
tool: async (client,
|
|
51858
|
-
const [result, apiCall] = await uniswapV3QuoteSellExactly(client,
|
|
52337
|
+
args: args66,
|
|
52338
|
+
tool: async (client, args67, ctx) => {
|
|
52339
|
+
const [result, apiCall] = await uniswapV3QuoteSellExactly(client, args67.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51859
52340
|
if (!result.ok) {
|
|
51860
52341
|
return {
|
|
51861
52342
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51870,9 +52351,9 @@ into account the current pool state and the specified fee tier.`,
|
|
|
51870
52351
|
|
|
51871
52352
|
// src/funcs/uniswapV3SwapBuyExactly.ts
|
|
51872
52353
|
function uniswapV3SwapBuyExactly(client, request, options) {
|
|
51873
|
-
return new APIPromise($
|
|
52354
|
+
return new APIPromise($do67(client, request, options));
|
|
51874
52355
|
}
|
|
51875
|
-
async function $
|
|
52356
|
+
async function $do67(client, request, options) {
|
|
51876
52357
|
const parsed = safeParse(request, (value) => UniswapBuyExactlyRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51877
52358
|
if (!parsed.ok) {
|
|
51878
52359
|
return [parsed, { status: "invalid" }];
|
|
@@ -51943,12 +52424,12 @@ var init_uniswapV3SwapBuyExactly = __esm(() => {
|
|
|
51943
52424
|
});
|
|
51944
52425
|
|
|
51945
52426
|
// src/mcp-server/tools/uniswapV3SwapBuyExactly.ts
|
|
51946
|
-
var
|
|
52427
|
+
var args67, tool$uniswapV3SwapBuyExactly;
|
|
51947
52428
|
var init_uniswapV3SwapBuyExactly2 = __esm(() => {
|
|
51948
52429
|
init_uniswapV3SwapBuyExactly();
|
|
51949
52430
|
init_components();
|
|
51950
52431
|
init_tools();
|
|
51951
|
-
|
|
52432
|
+
args67 = {
|
|
51952
52433
|
request: UniswapBuyExactlyRequest$inboundSchema
|
|
51953
52434
|
};
|
|
51954
52435
|
tool$uniswapV3SwapBuyExactly = {
|
|
@@ -51962,9 +52443,9 @@ The transaction is executed on the specified blockchain network, and the user mu
|
|
|
51962
52443
|
provide the necessary transaction details, including the token to buy, the token to
|
|
51963
52444
|
pay with, and the exact amount to receive. If the token being paid with is WETH and
|
|
51964
52445
|
needs to be wrapped, the appropriate amount will be wrapped automatically.`,
|
|
51965
|
-
args:
|
|
51966
|
-
tool: async (client,
|
|
51967
|
-
const [result, apiCall] = await uniswapV3SwapBuyExactly(client,
|
|
52446
|
+
args: args67,
|
|
52447
|
+
tool: async (client, args68, ctx) => {
|
|
52448
|
+
const [result, apiCall] = await uniswapV3SwapBuyExactly(client, args68.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
51968
52449
|
if (!result.ok) {
|
|
51969
52450
|
return {
|
|
51970
52451
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -51979,9 +52460,9 @@ needs to be wrapped, the appropriate amount will be wrapped automatically.`,
|
|
|
51979
52460
|
|
|
51980
52461
|
// src/funcs/uniswapV3SwapSellExactly.ts
|
|
51981
52462
|
function uniswapV3SwapSellExactly(client, request, options) {
|
|
51982
|
-
return new APIPromise($
|
|
52463
|
+
return new APIPromise($do68(client, request, options));
|
|
51983
52464
|
}
|
|
51984
|
-
async function $
|
|
52465
|
+
async function $do68(client, request, options) {
|
|
51985
52466
|
const parsed = safeParse(request, (value) => UniswapSellExactlyRequest$outboundSchema.parse(value), "Input validation failed");
|
|
51986
52467
|
if (!parsed.ok) {
|
|
51987
52468
|
return [parsed, { status: "invalid" }];
|
|
@@ -52052,12 +52533,12 @@ var init_uniswapV3SwapSellExactly = __esm(() => {
|
|
|
52052
52533
|
});
|
|
52053
52534
|
|
|
52054
52535
|
// src/mcp-server/tools/uniswapV3SwapSellExactly.ts
|
|
52055
|
-
var
|
|
52536
|
+
var args68, tool$uniswapV3SwapSellExactly;
|
|
52056
52537
|
var init_uniswapV3SwapSellExactly2 = __esm(() => {
|
|
52057
52538
|
init_uniswapV3SwapSellExactly();
|
|
52058
52539
|
init_components();
|
|
52059
52540
|
init_tools();
|
|
52060
|
-
|
|
52541
|
+
args68 = {
|
|
52061
52542
|
request: UniswapSellExactlyRequest$inboundSchema
|
|
52062
52543
|
};
|
|
52063
52544
|
tool$uniswapV3SwapSellExactly = {
|
|
@@ -52071,9 +52552,9 @@ The transaction is executed on the specified blockchain network, and the user mu
|
|
|
52071
52552
|
provide the necessary transaction details, including the token to sell, the token to
|
|
52072
52553
|
receive, and the amount to sell. If the token being sold is WETH and needs to be
|
|
52073
52554
|
wrapped, the appropriate amount will be wrapped automatically.`,
|
|
52074
|
-
args:
|
|
52075
|
-
tool: async (client,
|
|
52076
|
-
const [result, apiCall] = await uniswapV3SwapSellExactly(client,
|
|
52555
|
+
args: args68,
|
|
52556
|
+
tool: async (client, args69, ctx) => {
|
|
52557
|
+
const [result, apiCall] = await uniswapV3SwapSellExactly(client, args69.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52077
52558
|
if (!result.ok) {
|
|
52078
52559
|
return {
|
|
52079
52560
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52088,9 +52569,9 @@ wrapped, the appropriate amount will be wrapped automatically.`,
|
|
|
52088
52569
|
|
|
52089
52570
|
// src/funcs/universalAllowance.ts
|
|
52090
52571
|
function universalAllowance(client, request, options) {
|
|
52091
|
-
return new APIPromise($
|
|
52572
|
+
return new APIPromise($do69(client, request, options));
|
|
52092
52573
|
}
|
|
52093
|
-
async function $
|
|
52574
|
+
async function $do69(client, request, options) {
|
|
52094
52575
|
const parsed = safeParse(request, (value) => GenericAllowanceRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52095
52576
|
if (!parsed.ok) {
|
|
52096
52577
|
return [parsed, { status: "invalid" }];
|
|
@@ -52168,12 +52649,12 @@ var init_universalAllowance = __esm(() => {
|
|
|
52168
52649
|
});
|
|
52169
52650
|
|
|
52170
52651
|
// src/mcp-server/tools/universalAllowance.ts
|
|
52171
|
-
var
|
|
52652
|
+
var args69, tool$universalAllowance;
|
|
52172
52653
|
var init_universalAllowance2 = __esm(() => {
|
|
52173
52654
|
init_universalAllowance();
|
|
52174
52655
|
init_operations();
|
|
52175
52656
|
init_tools();
|
|
52176
|
-
|
|
52657
|
+
args69 = {
|
|
52177
52658
|
request: GenericAllowanceRequest$inboundSchema
|
|
52178
52659
|
};
|
|
52179
52660
|
tool$universalAllowance = {
|
|
@@ -52187,9 +52668,9 @@ tokens on their behalf.
|
|
|
52187
52668
|
This is a crucial step before engaging in any transactions or operations within
|
|
52188
52669
|
these protocols, ensuring that the protocol has the necessary permissions to manage
|
|
52189
52670
|
the user's tokens securely and efficiently.`,
|
|
52190
|
-
args:
|
|
52191
|
-
tool: async (client,
|
|
52192
|
-
const [result, apiCall] = await universalAllowance(client,
|
|
52671
|
+
args: args69,
|
|
52672
|
+
tool: async (client, args70, ctx) => {
|
|
52673
|
+
const [result, apiCall] = await universalAllowance(client, args70.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52193
52674
|
if (!result.ok) {
|
|
52194
52675
|
return {
|
|
52195
52676
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52204,9 +52685,9 @@ the user's tokens securely and efficiently.`,
|
|
|
52204
52685
|
|
|
52205
52686
|
// src/funcs/universalAllowanceSet.ts
|
|
52206
52687
|
function universalAllowanceSet(client, request, options) {
|
|
52207
|
-
return new APIPromise($
|
|
52688
|
+
return new APIPromise($do70(client, request, options));
|
|
52208
52689
|
}
|
|
52209
|
-
async function $
|
|
52690
|
+
async function $do70(client, request, options) {
|
|
52210
52691
|
const parsed = safeParse(request, (value) => IncreaseAllowanceRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52211
52692
|
if (!parsed.ok) {
|
|
52212
52693
|
return [parsed, { status: "invalid" }];
|
|
@@ -52277,12 +52758,12 @@ var init_universalAllowanceSet = __esm(() => {
|
|
|
52277
52758
|
});
|
|
52278
52759
|
|
|
52279
52760
|
// src/mcp-server/tools/universalAllowanceSet.ts
|
|
52280
|
-
var
|
|
52761
|
+
var args70, tool$universalAllowanceSet;
|
|
52281
52762
|
var init_universalAllowanceSet2 = __esm(() => {
|
|
52282
52763
|
init_universalAllowanceSet();
|
|
52283
52764
|
init_components();
|
|
52284
52765
|
init_tools();
|
|
52285
|
-
|
|
52766
|
+
args70 = {
|
|
52286
52767
|
request: IncreaseAllowanceRequest$inboundSchema
|
|
52287
52768
|
};
|
|
52288
52769
|
tool$universalAllowanceSet = {
|
|
@@ -52297,9 +52778,9 @@ authorize a protocol to spend a specified amount of tokens on behalf of the user
|
|
|
52297
52778
|
This operation is crucial for ensuring that the protocol can manage the user's
|
|
52298
52779
|
tokens securely and efficiently, enabling seamless transactions and operations
|
|
52299
52780
|
within the DeFi ecosystem.`,
|
|
52300
|
-
args:
|
|
52301
|
-
tool: async (client,
|
|
52302
|
-
const [result, apiCall] = await universalAllowanceSet(client,
|
|
52781
|
+
args: args70,
|
|
52782
|
+
tool: async (client, args71, ctx) => {
|
|
52783
|
+
const [result, apiCall] = await universalAllowanceSet(client, args71.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52303
52784
|
if (!result.ok) {
|
|
52304
52785
|
return {
|
|
52305
52786
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52314,9 +52795,9 @@ within the DeFi ecosystem.`,
|
|
|
52314
52795
|
|
|
52315
52796
|
// src/funcs/universalEns.ts
|
|
52316
52797
|
function universalEns(client, request, options) {
|
|
52317
|
-
return new APIPromise($
|
|
52798
|
+
return new APIPromise($do71(client, request, options));
|
|
52318
52799
|
}
|
|
52319
|
-
async function $
|
|
52800
|
+
async function $do71(client, request, options) {
|
|
52320
52801
|
const parsed = safeParse(request, (value) => GenericEnsRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52321
52802
|
if (!parsed.ok) {
|
|
52322
52803
|
return [parsed, { status: "invalid" }];
|
|
@@ -52392,12 +52873,12 @@ var init_universalEns = __esm(() => {
|
|
|
52392
52873
|
});
|
|
52393
52874
|
|
|
52394
52875
|
// src/mcp-server/tools/universalEns.ts
|
|
52395
|
-
var
|
|
52876
|
+
var args71, tool$universalEns;
|
|
52396
52877
|
var init_universalEns2 = __esm(() => {
|
|
52397
52878
|
init_universalEns();
|
|
52398
52879
|
init_operations();
|
|
52399
52880
|
init_tools();
|
|
52400
|
-
|
|
52881
|
+
args71 = {
|
|
52401
52882
|
request: GenericEnsRequest$inboundSchema
|
|
52402
52883
|
};
|
|
52403
52884
|
tool$universalEns = {
|
|
@@ -52408,9 +52889,9 @@ An ENS name is a string ending in \`.eth\`.
|
|
|
52408
52889
|
|
|
52409
52890
|
E.g. \`vitalik.eth\`. This endpoint can be used to
|
|
52410
52891
|
query the actual ethereum wallet address behind the ENS name.`,
|
|
52411
|
-
args:
|
|
52412
|
-
tool: async (client,
|
|
52413
|
-
const [result, apiCall] = await universalEns(client,
|
|
52892
|
+
args: args71,
|
|
52893
|
+
tool: async (client, args72, ctx) => {
|
|
52894
|
+
const [result, apiCall] = await universalEns(client, args72.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52414
52895
|
if (!result.ok) {
|
|
52415
52896
|
return {
|
|
52416
52897
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52425,9 +52906,9 @@ query the actual ethereum wallet address behind the ENS name.`,
|
|
|
52425
52906
|
|
|
52426
52907
|
// src/funcs/universalPortfolio.ts
|
|
52427
52908
|
function universalPortfolio(client, request, options) {
|
|
52428
|
-
return new APIPromise($
|
|
52909
|
+
return new APIPromise($do72(client, request, options));
|
|
52429
52910
|
}
|
|
52430
|
-
async function $
|
|
52911
|
+
async function $do72(client, request, options) {
|
|
52431
52912
|
const parsed = safeParse(request, (value) => GenericPortfolioRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52432
52913
|
if (!parsed.ok) {
|
|
52433
52914
|
return [parsed, { status: "invalid" }];
|
|
@@ -52503,12 +52984,12 @@ var init_universalPortfolio = __esm(() => {
|
|
|
52503
52984
|
});
|
|
52504
52985
|
|
|
52505
52986
|
// src/mcp-server/tools/universalPortfolio.ts
|
|
52506
|
-
var
|
|
52987
|
+
var args72, tool$universalPortfolio;
|
|
52507
52988
|
var init_universalPortfolio2 = __esm(() => {
|
|
52508
52989
|
init_universalPortfolio();
|
|
52509
52990
|
init_operations();
|
|
52510
52991
|
init_tools();
|
|
52511
|
-
|
|
52992
|
+
args72 = {
|
|
52512
52993
|
request: GenericPortfolioRequest$inboundSchema
|
|
52513
52994
|
};
|
|
52514
52995
|
tool$universalPortfolio = {
|
|
@@ -52519,9 +53000,9 @@ Fetch the detailed portfolio of a specific wallet address on a given blockchain.
|
|
|
52519
53000
|
|
|
52520
53001
|
This includes the total value of the portfolio in USD and a breakdown of token
|
|
52521
53002
|
balances, including their respective values and quantities.`,
|
|
52522
|
-
args:
|
|
52523
|
-
tool: async (client,
|
|
52524
|
-
const [result, apiCall] = await universalPortfolio(client,
|
|
53003
|
+
args: args72,
|
|
53004
|
+
tool: async (client, args73, ctx) => {
|
|
53005
|
+
const [result, apiCall] = await universalPortfolio(client, args73.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52525
53006
|
if (!result.ok) {
|
|
52526
53007
|
return {
|
|
52527
53008
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52536,9 +53017,9 @@ balances, including their respective values and quantities.`,
|
|
|
52536
53017
|
|
|
52537
53018
|
// src/funcs/universalSupportedTokens.ts
|
|
52538
53019
|
function universalSupportedTokens(client, request, options) {
|
|
52539
|
-
return new APIPromise($
|
|
53020
|
+
return new APIPromise($do73(client, request, options));
|
|
52540
53021
|
}
|
|
52541
|
-
async function $
|
|
53022
|
+
async function $do73(client, request, options) {
|
|
52542
53023
|
const parsed = safeParse(request, (value) => GenericSupportedTokensRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52543
53024
|
if (!parsed.ok) {
|
|
52544
53025
|
return [parsed, { status: "invalid" }];
|
|
@@ -52613,12 +53094,12 @@ var init_universalSupportedTokens = __esm(() => {
|
|
|
52613
53094
|
});
|
|
52614
53095
|
|
|
52615
53096
|
// src/mcp-server/tools/universalSupportedTokens.ts
|
|
52616
|
-
var
|
|
53097
|
+
var args73, tool$universalSupportedTokens;
|
|
52617
53098
|
var init_universalSupportedTokens2 = __esm(() => {
|
|
52618
53099
|
init_universalSupportedTokens();
|
|
52619
53100
|
init_operations();
|
|
52620
53101
|
init_tools();
|
|
52621
|
-
|
|
53102
|
+
args73 = {
|
|
52622
53103
|
request: GenericSupportedTokensRequest$inboundSchema
|
|
52623
53104
|
};
|
|
52624
53105
|
tool$universalSupportedTokens = {
|
|
@@ -52626,9 +53107,9 @@ var init_universalSupportedTokens2 = __esm(() => {
|
|
|
52626
53107
|
description: `List supported tokens
|
|
52627
53108
|
|
|
52628
53109
|
Get the list of supported tokens on a chain by the Compass API.`,
|
|
52629
|
-
args:
|
|
52630
|
-
tool: async (client,
|
|
52631
|
-
const [result, apiCall] = await universalSupportedTokens(client,
|
|
53110
|
+
args: args73,
|
|
53111
|
+
tool: async (client, args74, ctx) => {
|
|
53112
|
+
const [result, apiCall] = await universalSupportedTokens(client, args74.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52632
53113
|
if (!result.ok) {
|
|
52633
53114
|
return {
|
|
52634
53115
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52643,9 +53124,9 @@ Get the list of supported tokens on a chain by the Compass API.`,
|
|
|
52643
53124
|
|
|
52644
53125
|
// src/funcs/universalUnwrapWeth.ts
|
|
52645
53126
|
function universalUnwrapWeth(client, request, options) {
|
|
52646
|
-
return new APIPromise($
|
|
53127
|
+
return new APIPromise($do74(client, request, options));
|
|
52647
53128
|
}
|
|
52648
|
-
async function $
|
|
53129
|
+
async function $do74(client, request, options) {
|
|
52649
53130
|
const parsed = safeParse(request, (value) => UnwrapWethRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52650
53131
|
if (!parsed.ok) {
|
|
52651
53132
|
return [parsed, { status: "invalid" }];
|
|
@@ -52716,12 +53197,12 @@ var init_universalUnwrapWeth = __esm(() => {
|
|
|
52716
53197
|
});
|
|
52717
53198
|
|
|
52718
53199
|
// src/mcp-server/tools/universalUnwrapWeth.ts
|
|
52719
|
-
var
|
|
53200
|
+
var args74, tool$universalUnwrapWeth;
|
|
52720
53201
|
var init_universalUnwrapWeth2 = __esm(() => {
|
|
52721
53202
|
init_universalUnwrapWeth();
|
|
52722
53203
|
init_components();
|
|
52723
53204
|
init_tools();
|
|
52724
|
-
|
|
53205
|
+
args74 = {
|
|
52725
53206
|
request: UnwrapWethRequest$inboundSchema
|
|
52726
53207
|
};
|
|
52727
53208
|
tool$universalUnwrapWeth = {
|
|
@@ -52730,9 +53211,9 @@ var init_universalUnwrapWeth2 = __esm(() => {
|
|
|
52730
53211
|
|
|
52731
53212
|
Unwrapping WETH converts the ERC-20 compliant form of ETH back to native ETH that
|
|
52732
53213
|
can be used for gas and other native purposes.`,
|
|
52733
|
-
args:
|
|
52734
|
-
tool: async (client,
|
|
52735
|
-
const [result, apiCall] = await universalUnwrapWeth(client,
|
|
53214
|
+
args: args74,
|
|
53215
|
+
tool: async (client, args75, ctx) => {
|
|
53216
|
+
const [result, apiCall] = await universalUnwrapWeth(client, args75.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52736
53217
|
if (!result.ok) {
|
|
52737
53218
|
return {
|
|
52738
53219
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52747,9 +53228,9 @@ can be used for gas and other native purposes.`,
|
|
|
52747
53228
|
|
|
52748
53229
|
// src/funcs/universalVisualizePortfolio.ts
|
|
52749
53230
|
function universalVisualizePortfolio(client, request, options) {
|
|
52750
|
-
return new APIPromise($
|
|
53231
|
+
return new APIPromise($do75(client, request, options));
|
|
52751
53232
|
}
|
|
52752
|
-
async function $
|
|
53233
|
+
async function $do75(client, request, options) {
|
|
52753
53234
|
const parsed = safeParse(request, (value) => GenericVisualizePortfolioRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52754
53235
|
if (!parsed.ok) {
|
|
52755
53236
|
return [parsed, { status: "invalid" }];
|
|
@@ -52825,12 +53306,12 @@ var init_universalVisualizePortfolio = __esm(() => {
|
|
|
52825
53306
|
});
|
|
52826
53307
|
|
|
52827
53308
|
// src/mcp-server/tools/universalVisualizePortfolio.ts
|
|
52828
|
-
var
|
|
53309
|
+
var args75, tool$universalVisualizePortfolio;
|
|
52829
53310
|
var init_universalVisualizePortfolio2 = __esm(() => {
|
|
52830
53311
|
init_universalVisualizePortfolio();
|
|
52831
53312
|
init_operations();
|
|
52832
53313
|
init_tools();
|
|
52833
|
-
|
|
53314
|
+
args75 = {
|
|
52834
53315
|
request: GenericVisualizePortfolioRequest$inboundSchema
|
|
52835
53316
|
};
|
|
52836
53317
|
tool$universalVisualizePortfolio = {
|
|
@@ -52842,9 +53323,9 @@ Generate a visual representation of the token portfolio for a wallet address.
|
|
|
52842
53323
|
The response is an SVG image of a pie chart depicting the relative distribution of
|
|
52843
53324
|
tokens held, colored and labeled with token symbols, percentages and token values in
|
|
52844
53325
|
USD.`,
|
|
52845
|
-
args:
|
|
52846
|
-
tool: async (client,
|
|
52847
|
-
const [result, apiCall] = await universalVisualizePortfolio(client,
|
|
53326
|
+
args: args75,
|
|
53327
|
+
tool: async (client, args76, ctx) => {
|
|
53328
|
+
const [result, apiCall] = await universalVisualizePortfolio(client, args76.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52848
53329
|
if (!result.ok) {
|
|
52849
53330
|
return {
|
|
52850
53331
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52859,9 +53340,9 @@ USD.`,
|
|
|
52859
53340
|
|
|
52860
53341
|
// src/funcs/universalWrapEth.ts
|
|
52861
53342
|
function universalWrapEth(client, request, options) {
|
|
52862
|
-
return new APIPromise($
|
|
53343
|
+
return new APIPromise($do76(client, request, options));
|
|
52863
53344
|
}
|
|
52864
|
-
async function $
|
|
53345
|
+
async function $do76(client, request, options) {
|
|
52865
53346
|
const parsed = safeParse(request, (value) => WrapEthRequest$outboundSchema.parse(value), "Input validation failed");
|
|
52866
53347
|
if (!parsed.ok) {
|
|
52867
53348
|
return [parsed, { status: "invalid" }];
|
|
@@ -52932,12 +53413,12 @@ var init_universalWrapEth = __esm(() => {
|
|
|
52932
53413
|
});
|
|
52933
53414
|
|
|
52934
53415
|
// src/mcp-server/tools/universalWrapEth.ts
|
|
52935
|
-
var
|
|
53416
|
+
var args76, tool$universalWrapEth;
|
|
52936
53417
|
var init_universalWrapEth2 = __esm(() => {
|
|
52937
53418
|
init_universalWrapEth();
|
|
52938
53419
|
init_components();
|
|
52939
53420
|
init_tools();
|
|
52940
|
-
|
|
53421
|
+
args76 = {
|
|
52941
53422
|
request: WrapEthRequest$inboundSchema
|
|
52942
53423
|
};
|
|
52943
53424
|
tool$universalWrapEth = {
|
|
@@ -52946,9 +53427,9 @@ var init_universalWrapEth2 = __esm(() => {
|
|
|
52946
53427
|
|
|
52947
53428
|
Wrapping ETH creates an ERC20 compliant form of ETH that is typically needed for
|
|
52948
53429
|
it to be traded on DeFi protocols.`,
|
|
52949
|
-
args:
|
|
52950
|
-
tool: async (client,
|
|
52951
|
-
const [result, apiCall] = await universalWrapEth(client,
|
|
53430
|
+
args: args76,
|
|
53431
|
+
tool: async (client, args77, ctx) => {
|
|
53432
|
+
const [result, apiCall] = await universalWrapEth(client, args77.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
|
|
52952
53433
|
if (!result.ok) {
|
|
52953
53434
|
return {
|
|
52954
53435
|
content: [{ type: "text", text: result.error.message }],
|
|
@@ -52965,7 +53446,7 @@ it to be traded on DeFi protocols.`,
|
|
|
52965
53446
|
function createMCPServer(deps) {
|
|
52966
53447
|
const server = new McpServer({
|
|
52967
53448
|
name: "CompassApiSDK",
|
|
52968
|
-
version: "0.5.
|
|
53449
|
+
version: "0.5.14"
|
|
52969
53450
|
});
|
|
52970
53451
|
const client = new CompassApiSDKCore({
|
|
52971
53452
|
apiKeyAuth: deps.apiKeyAuth,
|
|
@@ -53051,6 +53532,9 @@ function createMCPServer(deps) {
|
|
|
53051
53532
|
tool(tool$pendleRedeemYield);
|
|
53052
53533
|
tool(tool$pendleAddLiquidity);
|
|
53053
53534
|
tool(tool$pendleRemoveLiquidity);
|
|
53535
|
+
tool(tool$transactionBatchingAuthorization);
|
|
53536
|
+
tool(tool$transactionBatchingExecute);
|
|
53537
|
+
tool(tool$transactionBatchingAaveLoop);
|
|
53054
53538
|
tool(tool$smartAccountAccountBatchedUserOperations);
|
|
53055
53539
|
return server;
|
|
53056
53540
|
}
|
|
@@ -53114,6 +53598,9 @@ var init_server2 = __esm(() => {
|
|
|
53114
53598
|
init_tokenBalance2();
|
|
53115
53599
|
init_tokenPrice2();
|
|
53116
53600
|
init_tokenTransfer2();
|
|
53601
|
+
init_transactionBatchingAaveLoop2();
|
|
53602
|
+
init_transactionBatchingAuthorization2();
|
|
53603
|
+
init_transactionBatchingExecute2();
|
|
53117
53604
|
init_uniswapV3LiquidityProvisionIncrease2();
|
|
53118
53605
|
init_uniswapV3LiquidityProvisionInRange2();
|
|
53119
53606
|
init_uniswapV3LiquidityProvisionMint2();
|
|
@@ -54322,7 +54809,7 @@ var routes = an({
|
|
|
54322
54809
|
var app = He(routes, {
|
|
54323
54810
|
name: "mcp",
|
|
54324
54811
|
versionInfo: {
|
|
54325
|
-
currentVersion: "0.5.
|
|
54812
|
+
currentVersion: "0.5.14"
|
|
54326
54813
|
}
|
|
54327
54814
|
});
|
|
54328
54815
|
zt(app, process3.argv.slice(2), buildContext(process3));
|
|
@@ -54330,5 +54817,5 @@ export {
|
|
|
54330
54817
|
app
|
|
54331
54818
|
};
|
|
54332
54819
|
|
|
54333
|
-
//# debugId=
|
|
54820
|
+
//# debugId=15D9FD6FAC35FAB164756E2164756E21
|
|
54334
54821
|
//# sourceMappingURL=mcp-server.js.map
|