@settlemint/sdk-mcp 2.0.0 → 2.1.1-main25da2665
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/mcp.js +158 -70
- package/dist/mcp.js.map +17 -16
- package/package.json +5 -5
package/dist/mcp.js
CHANGED
|
@@ -22251,6 +22251,9 @@ var require_utils2 = __commonJS((exports) => {
|
|
|
22251
22251
|
exports.isNodeReadable = isNodeReadable;
|
|
22252
22252
|
exports.isIterable = isIterable;
|
|
22253
22253
|
exports.shouldRedirect = shouldRedirect;
|
|
22254
|
+
exports.wrapIncomingMessageWithPassthrough = wrapIncomingMessageWithPassthrough;
|
|
22255
|
+
var node_stream_1 = __require("node:stream");
|
|
22256
|
+
var promises_1 = __require("node:stream/promises");
|
|
22254
22257
|
function isHeadersInstance(obj) {
|
|
22255
22258
|
return obj?.forEach != null;
|
|
22256
22259
|
}
|
|
@@ -22286,6 +22289,19 @@ var require_utils2 = __commonJS((exports) => {
|
|
|
22286
22289
|
function shouldRedirect(status) {
|
|
22287
22290
|
return status === 301 || status === 302 || status === 303 || status === 307 || status === 308;
|
|
22288
22291
|
}
|
|
22292
|
+
function wrapIncomingMessageWithPassthrough({ incomingMessage, signal, passThrough = new node_stream_1.PassThrough, onError = (e) => {
|
|
22293
|
+
passThrough.destroy(e);
|
|
22294
|
+
} }) {
|
|
22295
|
+
(0, promises_1.pipeline)(incomingMessage, passThrough, {
|
|
22296
|
+
signal,
|
|
22297
|
+
end: true
|
|
22298
|
+
}).then(() => {
|
|
22299
|
+
if (!incomingMessage.destroyed) {
|
|
22300
|
+
incomingMessage.resume();
|
|
22301
|
+
}
|
|
22302
|
+
}).catch(onError);
|
|
22303
|
+
return passThrough;
|
|
22304
|
+
}
|
|
22289
22305
|
});
|
|
22290
22306
|
|
|
22291
22307
|
// ../../node_modules/@whatwg-node/node-fetch/cjs/ReadableStream.js
|
|
@@ -23324,7 +23340,6 @@ var require_Body = __commonJS((exports) => {
|
|
|
23324
23340
|
var node_buffer_1 = __require("node:buffer");
|
|
23325
23341
|
var node_http_1 = __require("node:http");
|
|
23326
23342
|
var node_stream_1 = __require("node:stream");
|
|
23327
|
-
var promises_1 = __require("node:stream/promises");
|
|
23328
23343
|
var busboy_1 = tslib_1.__importDefault(require_lib());
|
|
23329
23344
|
var promise_helpers_1 = require_cjs();
|
|
23330
23345
|
var Blob_js_1 = require_Blob();
|
|
@@ -23716,17 +23731,10 @@ var require_Body = __commonJS((exports) => {
|
|
|
23716
23731
|
};
|
|
23717
23732
|
}
|
|
23718
23733
|
if (bodyInit instanceof node_http_1.IncomingMessage) {
|
|
23719
|
-
const passThrough =
|
|
23734
|
+
const passThrough = (0, utils_js_1.wrapIncomingMessageWithPassthrough)({
|
|
23735
|
+
incomingMessage: bodyInit,
|
|
23720
23736
|
signal
|
|
23721
23737
|
});
|
|
23722
|
-
if (signal) {
|
|
23723
|
-
(0, promises_1.pipeline)(bodyInit, passThrough, {
|
|
23724
|
-
signal,
|
|
23725
|
-
end: true
|
|
23726
|
-
}).catch((e) => {
|
|
23727
|
-
passThrough.destroy(e);
|
|
23728
|
-
});
|
|
23729
|
-
}
|
|
23730
23738
|
return {
|
|
23731
23739
|
bodyType: BodyInitType.Readable,
|
|
23732
23740
|
contentType: null,
|
|
@@ -24141,7 +24149,6 @@ var require_fetchCurl = __commonJS((exports) => {
|
|
|
24141
24149
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24142
24150
|
exports.fetchCurl = fetchCurl;
|
|
24143
24151
|
var node_stream_1 = __require("node:stream");
|
|
24144
|
-
var promises_1 = __require("node:stream/promises");
|
|
24145
24152
|
var node_tls_1 = __require("node:tls");
|
|
24146
24153
|
var promise_helpers_1 = require_cjs();
|
|
24147
24154
|
var Response_js_1 = require_Response();
|
|
@@ -24232,15 +24239,11 @@ var require_fetchCurl = __commonJS((exports) => {
|
|
|
24232
24239
|
}
|
|
24233
24240
|
});
|
|
24234
24241
|
curlHandle.once("stream", function streamListener(stream, status, headersBuf) {
|
|
24235
|
-
const outputStream =
|
|
24236
|
-
|
|
24237
|
-
|
|
24238
|
-
|
|
24239
|
-
})
|
|
24240
|
-
if (!stream.destroyed) {
|
|
24241
|
-
stream.resume();
|
|
24242
|
-
}
|
|
24243
|
-
}).catch(deferredPromise.reject);
|
|
24242
|
+
const outputStream = (0, utils_js_1.wrapIncomingMessageWithPassthrough)({
|
|
24243
|
+
incomingMessage: stream,
|
|
24244
|
+
signal: fetchRequest.signal,
|
|
24245
|
+
onError: deferredPromise.reject
|
|
24246
|
+
});
|
|
24244
24247
|
const headersFlat = headersBuf.toString("utf8").split(/\r?\n|\r/g).filter((headerFilter) => {
|
|
24245
24248
|
if (headerFilter && !headerFilter.startsWith("HTTP/")) {
|
|
24246
24249
|
if (fetchRequest.redirect === "error" && headerFilter.toLowerCase().includes("location") && (0, utils_js_1.shouldRedirect)(status)) {
|
|
@@ -24427,7 +24430,6 @@ var require_fetchNodeHttp = __commonJS((exports) => {
|
|
|
24427
24430
|
var node_http_1 = __require("node:http");
|
|
24428
24431
|
var node_https_1 = __require("node:https");
|
|
24429
24432
|
var node_stream_1 = __require("node:stream");
|
|
24430
|
-
var promises_1 = __require("node:stream/promises");
|
|
24431
24433
|
var node_zlib_1 = __require("node:zlib");
|
|
24432
24434
|
var Request_js_1 = require_Request();
|
|
24433
24435
|
var Response_js_1 = require_Response();
|
|
@@ -24505,14 +24507,12 @@ var require_fetchNodeHttp = __commonJS((exports) => {
|
|
|
24505
24507
|
}
|
|
24506
24508
|
}
|
|
24507
24509
|
if (outputStream != null) {
|
|
24508
|
-
(0,
|
|
24510
|
+
outputStream = (0, utils_js_1.wrapIncomingMessageWithPassthrough)({
|
|
24511
|
+
incomingMessage: nodeResponse,
|
|
24512
|
+
passThrough: outputStream,
|
|
24509
24513
|
signal: fetchRequest.signal,
|
|
24510
|
-
|
|
24511
|
-
})
|
|
24512
|
-
if (!nodeResponse.destroyed) {
|
|
24513
|
-
nodeResponse.resume();
|
|
24514
|
-
}
|
|
24515
|
-
}).catch(reject);
|
|
24514
|
+
onError: reject
|
|
24515
|
+
});
|
|
24516
24516
|
}
|
|
24517
24517
|
const statusCode = nodeResponse.statusCode || 200;
|
|
24518
24518
|
let statusText = nodeResponse.statusMessage || node_http_1.STATUS_CODES[statusCode];
|
|
@@ -27223,7 +27223,7 @@ var require_dist2 = __commonJS((exports) => {
|
|
|
27223
27223
|
// ../../node_modules/@dotenvx/dotenvx/package.json
|
|
27224
27224
|
var require_package = __commonJS((exports, module) => {
|
|
27225
27225
|
module.exports = {
|
|
27226
|
-
version: "1.39.
|
|
27226
|
+
version: "1.39.1",
|
|
27227
27227
|
name: "@dotenvx/dotenvx",
|
|
27228
27228
|
description: "a better dotenv–from the creator of `dotenv`",
|
|
27229
27229
|
author: "@motdotla",
|
|
@@ -29715,7 +29715,7 @@ var require_fsx = __commonJS((exports, module) => {
|
|
|
29715
29715
|
var require_package2 = __commonJS((exports, module) => {
|
|
29716
29716
|
module.exports = {
|
|
29717
29717
|
name: "dotenv",
|
|
29718
|
-
version: "16.
|
|
29718
|
+
version: "16.5.0",
|
|
29719
29719
|
description: "Loads environment variables from .env file",
|
|
29720
29720
|
main: "lib/main.js",
|
|
29721
29721
|
types: "lib/main.d.ts",
|
|
@@ -29746,6 +29746,7 @@ var require_package2 = __commonJS((exports, module) => {
|
|
|
29746
29746
|
type: "git",
|
|
29747
29747
|
url: "git://github.com/motdotla/dotenv.git"
|
|
29748
29748
|
},
|
|
29749
|
+
homepage: "https://github.com/motdotla/dotenv#readme",
|
|
29749
29750
|
funding: "https://dotenvx.com",
|
|
29750
29751
|
keywords: [
|
|
29751
29752
|
"dotenv",
|
|
@@ -29831,9 +29832,6 @@ var require_main = __commonJS((exports, module) => {
|
|
|
29831
29832
|
}
|
|
29832
29833
|
return DotenvModule.parse(decrypted);
|
|
29833
29834
|
}
|
|
29834
|
-
function _log(message) {
|
|
29835
|
-
console.log(`[dotenv@${version}][INFO] ${message}`);
|
|
29836
|
-
}
|
|
29837
29835
|
function _warn(message) {
|
|
29838
29836
|
console.log(`[dotenv@${version}][WARN] ${message}`);
|
|
29839
29837
|
}
|
|
@@ -29906,7 +29904,10 @@ var require_main = __commonJS((exports, module) => {
|
|
|
29906
29904
|
return envPath[0] === "~" ? path.join(os.homedir(), envPath.slice(1)) : envPath;
|
|
29907
29905
|
}
|
|
29908
29906
|
function _configVault(options) {
|
|
29909
|
-
|
|
29907
|
+
const debug = Boolean(options && options.debug);
|
|
29908
|
+
if (debug) {
|
|
29909
|
+
_debug("Loading env from encrypted .env.vault");
|
|
29910
|
+
}
|
|
29910
29911
|
const parsed = DotenvModule._parseVault(options);
|
|
29911
29912
|
let processEnv = process.env;
|
|
29912
29913
|
if (options && options.processEnv != null) {
|
|
@@ -42648,17 +42649,24 @@ function prepareResult({ options, pointerOptionMap, validSources }) {
|
|
|
42648
42649
|
debugTimerStart("@graphql-tools/load: prepareResult");
|
|
42649
42650
|
const pointerList = Object.keys(pointerOptionMap);
|
|
42650
42651
|
if (pointerList.length > 0 && validSources.length === 0) {
|
|
42651
|
-
throw new
|
|
42652
|
-
Unable to find any GraphQL type definitions for the following pointers:
|
|
42653
|
-
${pointerList.map((p) => `
|
|
42654
|
-
- ${p}
|
|
42655
|
-
`)}`);
|
|
42652
|
+
throw new NoTypeDefinitionsFound(pointerList);
|
|
42656
42653
|
}
|
|
42657
42654
|
const sortedResult = options.sort ? validSources.sort((left, right) => compareStrings(left.location, right.location)) : validSources;
|
|
42658
42655
|
debugTimerEnd("@graphql-tools/load: prepareResult");
|
|
42659
42656
|
return sortedResult;
|
|
42660
42657
|
}
|
|
42661
42658
|
|
|
42659
|
+
class NoTypeDefinitionsFound extends Error {
|
|
42660
|
+
constructor(pointerList) {
|
|
42661
|
+
super(`
|
|
42662
|
+
Unable to find any GraphQL type definitions for the following pointers:
|
|
42663
|
+
${pointerList.map((p) => `
|
|
42664
|
+
- ${p}
|
|
42665
|
+
`)}`);
|
|
42666
|
+
this.name = "NoTypeDefinitionsFound";
|
|
42667
|
+
}
|
|
42668
|
+
}
|
|
42669
|
+
|
|
42662
42670
|
// ../../node_modules/@graphql-tools/load/esm/schema.js
|
|
42663
42671
|
var import_graphql42 = __toESM(require_graphql2(), 1);
|
|
42664
42672
|
|
|
@@ -44523,6 +44531,58 @@ function buildGraphQLWSExecutor(clientOptionsOrClient) {
|
|
|
44523
44531
|
return executor2;
|
|
44524
44532
|
}
|
|
44525
44533
|
|
|
44534
|
+
// ../../node_modules/@graphql-hive/signal/dist/index.js
|
|
44535
|
+
var isNode = !globalThis.Bun && globalThis.process?.release?.name === "node";
|
|
44536
|
+
var anySignalRegistry = isNode ? new FinalizationRegistry((cb) => cb()) : null;
|
|
44537
|
+
var controllerInSignalSy = Symbol("CONTROLLER_IN_SIGNAL");
|
|
44538
|
+
function abortSignalAny(signals) {
|
|
44539
|
+
if (signals.length === 0) {
|
|
44540
|
+
return;
|
|
44541
|
+
}
|
|
44542
|
+
if (signals.length === 1) {
|
|
44543
|
+
return signals[0];
|
|
44544
|
+
}
|
|
44545
|
+
if (!isNode) {
|
|
44546
|
+
return AbortSignal.any(signals);
|
|
44547
|
+
}
|
|
44548
|
+
for (const signal of signals) {
|
|
44549
|
+
if (signal.aborted) {
|
|
44550
|
+
return signal;
|
|
44551
|
+
}
|
|
44552
|
+
}
|
|
44553
|
+
const ctrl = new AbortController;
|
|
44554
|
+
const ctrlRef = new WeakRef(ctrl);
|
|
44555
|
+
const eventListenerPairs = [];
|
|
44556
|
+
let retainedSignalsCount = signals.length;
|
|
44557
|
+
for (const signal of signals) {
|
|
44558
|
+
let abort2 = function() {
|
|
44559
|
+
ctrlRef.deref()?.abort(signalRef.deref()?.reason);
|
|
44560
|
+
};
|
|
44561
|
+
const signalRef = new WeakRef(signal);
|
|
44562
|
+
signal.addEventListener("abort", abort2);
|
|
44563
|
+
eventListenerPairs.push([signalRef, abort2]);
|
|
44564
|
+
anySignalRegistry.register(signal, () => !--retainedSignalsCount && dispose(), signal);
|
|
44565
|
+
}
|
|
44566
|
+
function dispose() {
|
|
44567
|
+
for (const [signalRef, abort2] of eventListenerPairs) {
|
|
44568
|
+
const signal = signalRef.deref();
|
|
44569
|
+
if (signal) {
|
|
44570
|
+
signal.removeEventListener("abort", abort2);
|
|
44571
|
+
anySignalRegistry.unregister(signal);
|
|
44572
|
+
}
|
|
44573
|
+
const ctrl2 = ctrlRef.deref();
|
|
44574
|
+
if (ctrl2) {
|
|
44575
|
+
anySignalRegistry.unregister(ctrl2.signal);
|
|
44576
|
+
delete ctrl2.signal[controllerInSignalSy];
|
|
44577
|
+
}
|
|
44578
|
+
}
|
|
44579
|
+
}
|
|
44580
|
+
ctrl.signal.addEventListener("abort", dispose);
|
|
44581
|
+
anySignalRegistry.register(ctrl.signal, dispose, ctrl.signal);
|
|
44582
|
+
ctrl.signal[controllerInSignalSy] = ctrl;
|
|
44583
|
+
return ctrl.signal;
|
|
44584
|
+
}
|
|
44585
|
+
|
|
44526
44586
|
// ../../node_modules/@whatwg-node/fetch/dist/node-ponyfill.js
|
|
44527
44587
|
var createNodePonyfill = require_create_node_ponyfill();
|
|
44528
44588
|
var shouldSkipPonyfill = require_shouldSkipPonyfill();
|
|
@@ -46013,9 +46073,10 @@ function prepareGETUrl({
|
|
|
46013
46073
|
}
|
|
46014
46074
|
function buildHTTPExecutor(options) {
|
|
46015
46075
|
const printFn = options?.print ?? defaultPrintFn;
|
|
46016
|
-
|
|
46076
|
+
let disposeCtrl;
|
|
46017
46077
|
const serviceName = options?.serviceName;
|
|
46018
46078
|
const baseExecutor = (request, excludeQuery) => {
|
|
46079
|
+
disposeCtrl ||= new AbortController;
|
|
46019
46080
|
if (disposeCtrl.signal.aborted) {
|
|
46020
46081
|
return createResultForAbort(disposeCtrl.signal.reason);
|
|
46021
46082
|
}
|
|
@@ -46059,8 +46120,9 @@ function buildHTTPExecutor(options) {
|
|
|
46059
46120
|
if (subscriptionCtrl) {
|
|
46060
46121
|
signals.push(subscriptionCtrl.signal);
|
|
46061
46122
|
}
|
|
46062
|
-
const signal =
|
|
46123
|
+
const signal = abortSignalAny(signals);
|
|
46063
46124
|
const upstreamErrorExtensions = {
|
|
46125
|
+
code: "DOWNSTREAM_SERVICE_ERROR",
|
|
46064
46126
|
serviceName,
|
|
46065
46127
|
request: {
|
|
46066
46128
|
method
|
|
@@ -46217,6 +46279,14 @@ function buildHTTPExecutor(options) {
|
|
|
46217
46279
|
]
|
|
46218
46280
|
};
|
|
46219
46281
|
}
|
|
46282
|
+
} else {
|
|
46283
|
+
return {
|
|
46284
|
+
errors: [
|
|
46285
|
+
createGraphQLError("No response returned", {
|
|
46286
|
+
extensions: upstreamErrorExtensions
|
|
46287
|
+
})
|
|
46288
|
+
]
|
|
46289
|
+
};
|
|
46220
46290
|
}
|
|
46221
46291
|
} else {
|
|
46222
46292
|
return result;
|
|
@@ -46240,7 +46310,7 @@ function buildHTTPExecutor(options) {
|
|
|
46240
46310
|
let result;
|
|
46241
46311
|
let attempt = 0;
|
|
46242
46312
|
function retryAttempt() {
|
|
46243
|
-
if (disposeCtrl
|
|
46313
|
+
if (disposeCtrl?.signal.aborted) {
|
|
46244
46314
|
return createResultForAbort(disposeCtrl.signal.reason);
|
|
46245
46315
|
}
|
|
46246
46316
|
attempt++;
|
|
@@ -46267,14 +46337,16 @@ function buildHTTPExecutor(options) {
|
|
|
46267
46337
|
[DisposableSymbols.dispose]: {
|
|
46268
46338
|
get() {
|
|
46269
46339
|
return function dispose() {
|
|
46270
|
-
|
|
46340
|
+
disposeCtrl?.abort(options?.getDisposeReason?.());
|
|
46341
|
+
disposeCtrl = undefined;
|
|
46271
46342
|
};
|
|
46272
46343
|
}
|
|
46273
46344
|
},
|
|
46274
46345
|
[DisposableSymbols.asyncDispose]: {
|
|
46275
46346
|
get() {
|
|
46276
46347
|
return function asyncDispose() {
|
|
46277
|
-
|
|
46348
|
+
disposeCtrl?.abort(options?.getDisposeReason?.());
|
|
46349
|
+
disposeCtrl = undefined;
|
|
46278
46350
|
};
|
|
46279
46351
|
}
|
|
46280
46352
|
}
|
|
@@ -46894,13 +46966,14 @@ function executeField(exeContext, parentType, source, fieldNodes, path, asyncPay
|
|
|
46894
46966
|
if (isPromise(completed)) {
|
|
46895
46967
|
return completed.then(undefined, (rawError) => {
|
|
46896
46968
|
if (rawError instanceof AggregateError) {
|
|
46897
|
-
|
|
46969
|
+
let result2;
|
|
46970
|
+
for (let rawErrorItem of rawError.errors) {
|
|
46898
46971
|
rawErrorItem = coerceError(rawErrorItem);
|
|
46899
46972
|
const error2 = import_graphql47.locatedError(rawErrorItem, fieldNodes, pathToArray(path));
|
|
46900
|
-
|
|
46973
|
+
result2 = handleFieldError(error2, returnType, errors2);
|
|
46901
46974
|
filterSubsequentPayloads(exeContext, path, asyncPayloadRecord);
|
|
46902
|
-
|
|
46903
|
-
|
|
46975
|
+
}
|
|
46976
|
+
return result2;
|
|
46904
46977
|
}
|
|
46905
46978
|
rawError = coerceError(rawError);
|
|
46906
46979
|
const error = import_graphql47.locatedError(rawError, fieldNodes, pathToArray(path));
|
|
@@ -46912,11 +46985,14 @@ function executeField(exeContext, parentType, source, fieldNodes, path, asyncPay
|
|
|
46912
46985
|
return completed;
|
|
46913
46986
|
} catch (rawError) {
|
|
46914
46987
|
if (rawError instanceof AggregateError) {
|
|
46915
|
-
|
|
46916
|
-
|
|
46917
|
-
|
|
46918
|
-
|
|
46919
|
-
|
|
46988
|
+
let result;
|
|
46989
|
+
for (let rawErrorItem of rawError.errors) {
|
|
46990
|
+
rawErrorItem = coerceError(rawErrorItem);
|
|
46991
|
+
const error2 = import_graphql47.locatedError(rawErrorItem, fieldNodes, pathToArray(path));
|
|
46992
|
+
result = handleFieldError(error2, returnType, errors2);
|
|
46993
|
+
filterSubsequentPayloads(exeContext, path, asyncPayloadRecord);
|
|
46994
|
+
}
|
|
46995
|
+
return result;
|
|
46920
46996
|
}
|
|
46921
46997
|
const coercedError = coerceError(rawError);
|
|
46922
46998
|
const error = import_graphql47.locatedError(coercedError, fieldNodes, pathToArray(path));
|
|
@@ -54582,6 +54658,7 @@ var InitializeRequestSchema = RequestSchema.extend({
|
|
|
54582
54658
|
var ServerCapabilitiesSchema = z.object({
|
|
54583
54659
|
experimental: z.optional(z.object({}).passthrough()),
|
|
54584
54660
|
logging: z.optional(z.object({}).passthrough()),
|
|
54661
|
+
completions: z.optional(z.object({}).passthrough()),
|
|
54585
54662
|
prompts: z.optional(z.object({
|
|
54586
54663
|
listChanged: z.optional(z.boolean())
|
|
54587
54664
|
}).passthrough()),
|
|
@@ -54719,6 +54796,11 @@ var ImageContentSchema = z.object({
|
|
|
54719
54796
|
data: z.string().base64(),
|
|
54720
54797
|
mimeType: z.string()
|
|
54721
54798
|
}).passthrough();
|
|
54799
|
+
var AudioContentSchema = z.object({
|
|
54800
|
+
type: z.literal("audio"),
|
|
54801
|
+
data: z.string().base64(),
|
|
54802
|
+
mimeType: z.string()
|
|
54803
|
+
}).passthrough();
|
|
54722
54804
|
var EmbeddedResourceSchema = z.object({
|
|
54723
54805
|
type: z.literal("resource"),
|
|
54724
54806
|
resource: z.union([TextResourceContentsSchema, BlobResourceContentsSchema])
|
|
@@ -54728,6 +54810,7 @@ var PromptMessageSchema = z.object({
|
|
|
54728
54810
|
content: z.union([
|
|
54729
54811
|
TextContentSchema,
|
|
54730
54812
|
ImageContentSchema,
|
|
54813
|
+
AudioContentSchema,
|
|
54731
54814
|
EmbeddedResourceSchema
|
|
54732
54815
|
])
|
|
54733
54816
|
}).passthrough();
|
|
@@ -54753,7 +54836,7 @@ var ListToolsResultSchema = PaginatedResultSchema.extend({
|
|
|
54753
54836
|
tools: z.array(ToolSchema)
|
|
54754
54837
|
});
|
|
54755
54838
|
var CallToolResultSchema = ResultSchema.extend({
|
|
54756
|
-
content: z.array(z.union([TextContentSchema, ImageContentSchema, EmbeddedResourceSchema])),
|
|
54839
|
+
content: z.array(z.union([TextContentSchema, ImageContentSchema, AudioContentSchema, EmbeddedResourceSchema])),
|
|
54757
54840
|
isError: z.boolean().default(false).optional()
|
|
54758
54841
|
});
|
|
54759
54842
|
var CompatibilityCallToolResultSchema = CallToolResultSchema.or(ResultSchema.extend({
|
|
@@ -54804,7 +54887,7 @@ var ModelPreferencesSchema = z.object({
|
|
|
54804
54887
|
}).passthrough();
|
|
54805
54888
|
var SamplingMessageSchema = z.object({
|
|
54806
54889
|
role: z.enum(["user", "assistant"]),
|
|
54807
|
-
content: z.union([TextContentSchema, ImageContentSchema])
|
|
54890
|
+
content: z.union([TextContentSchema, ImageContentSchema, AudioContentSchema])
|
|
54808
54891
|
}).passthrough();
|
|
54809
54892
|
var CreateMessageRequestSchema = RequestSchema.extend({
|
|
54810
54893
|
method: z.literal("sampling/createMessage"),
|
|
@@ -54825,7 +54908,8 @@ var CreateMessageResultSchema = ResultSchema.extend({
|
|
|
54825
54908
|
role: z.enum(["user", "assistant"]),
|
|
54826
54909
|
content: z.discriminatedUnion("type", [
|
|
54827
54910
|
TextContentSchema,
|
|
54828
|
-
ImageContentSchema
|
|
54911
|
+
ImageContentSchema,
|
|
54912
|
+
AudioContentSchema
|
|
54829
54913
|
])
|
|
54830
54914
|
});
|
|
54831
54915
|
var ResourceReferenceSchema = z.object({
|
|
@@ -54950,12 +55034,13 @@ class Protocol {
|
|
|
54950
55034
|
});
|
|
54951
55035
|
this.setRequestHandler(PingRequestSchema, (_request) => ({}));
|
|
54952
55036
|
}
|
|
54953
|
-
_setupTimeout(messageId, timeout, maxTotalTimeout, onTimeout) {
|
|
55037
|
+
_setupTimeout(messageId, timeout, maxTotalTimeout, onTimeout, resetTimeoutOnProgress = false) {
|
|
54954
55038
|
this._timeoutInfo.set(messageId, {
|
|
54955
55039
|
timeoutId: setTimeout(onTimeout, timeout),
|
|
54956
55040
|
startTime: Date.now(),
|
|
54957
55041
|
timeout,
|
|
54958
55042
|
maxTotalTimeout,
|
|
55043
|
+
resetTimeoutOnProgress,
|
|
54959
55044
|
onTimeout
|
|
54960
55045
|
});
|
|
54961
55046
|
}
|
|
@@ -55078,7 +55163,8 @@ class Protocol {
|
|
|
55078
55163
|
return;
|
|
55079
55164
|
}
|
|
55080
55165
|
const responseHandler = this._responseHandlers.get(messageId);
|
|
55081
|
-
|
|
55166
|
+
const timeoutInfo = this._timeoutInfo.get(messageId);
|
|
55167
|
+
if (timeoutInfo && responseHandler && timeoutInfo.resetTimeoutOnProgress) {
|
|
55082
55168
|
try {
|
|
55083
55169
|
this._resetTimeout(messageId);
|
|
55084
55170
|
} catch (error) {
|
|
@@ -55114,7 +55200,7 @@ class Protocol {
|
|
|
55114
55200
|
}
|
|
55115
55201
|
request(request, resultSchema, options) {
|
|
55116
55202
|
return new Promise((resolve, reject2) => {
|
|
55117
|
-
var _a, _b, _c, _d;
|
|
55203
|
+
var _a, _b, _c, _d, _e;
|
|
55118
55204
|
if (!this._transport) {
|
|
55119
55205
|
reject2(new Error("Not connected"));
|
|
55120
55206
|
return;
|
|
@@ -55172,7 +55258,7 @@ class Protocol {
|
|
|
55172
55258
|
});
|
|
55173
55259
|
const timeout = (_d = options === null || options === undefined ? undefined : options.timeout) !== null && _d !== undefined ? _d : DEFAULT_REQUEST_TIMEOUT_MSEC;
|
|
55174
55260
|
const timeoutHandler = () => cancel(new McpError(ErrorCode.RequestTimeout, "Request timed out", { timeout }));
|
|
55175
|
-
this._setupTimeout(messageId, timeout, options === null || options === undefined ? undefined : options.maxTotalTimeout, timeoutHandler);
|
|
55261
|
+
this._setupTimeout(messageId, timeout, options === null || options === undefined ? undefined : options.maxTotalTimeout, timeoutHandler, (_e = options === null || options === undefined ? undefined : options.resetTimeoutOnProgress) !== null && _e !== undefined ? _e : false);
|
|
55176
55262
|
this._transport.send(jsonrpcRequest).catch((error) => {
|
|
55177
55263
|
this._cleanupTimeout(messageId);
|
|
55178
55264
|
reject2(error);
|
|
@@ -56966,7 +57052,7 @@ class ReadBuffer {
|
|
|
56966
57052
|
if (index === -1) {
|
|
56967
57053
|
return null;
|
|
56968
57054
|
}
|
|
56969
|
-
const line = this._buffer.toString("utf8", 0, index);
|
|
57055
|
+
const line = this._buffer.toString("utf8", 0, index).replace(/\r$/, "");
|
|
56970
57056
|
this._buffer = this._buffer.subarray(index + 1);
|
|
56971
57057
|
return deserializeMessage(line);
|
|
56972
57058
|
}
|
|
@@ -62475,7 +62561,8 @@ var DotEnvSchema = z.object({
|
|
|
62475
62561
|
SETTLEMINT_BLOCKSCOUT: UniqueNameSchema.optional(),
|
|
62476
62562
|
SETTLEMINT_BLOCKSCOUT_GRAPHQL_ENDPOINT: UrlSchema.optional(),
|
|
62477
62563
|
SETTLEMINT_BLOCKSCOUT_UI_ENDPOINT: UrlSchema.optional(),
|
|
62478
|
-
SETTLEMINT_NEW_PROJECT_NAME: z.string().optional()
|
|
62564
|
+
SETTLEMINT_NEW_PROJECT_NAME: z.string().optional(),
|
|
62565
|
+
SETTLEMINT_LOG_LEVEL: z.enum(["debug", "info", "warn", "error", "none"]).default("warn")
|
|
62479
62566
|
});
|
|
62480
62567
|
var DotEnvSchemaPartial = DotEnvSchema.partial();
|
|
62481
62568
|
var IdSchema = z.union([
|
|
@@ -62579,7 +62666,8 @@ var DotEnvSchema2 = z.object({
|
|
|
62579
62666
|
SETTLEMINT_BLOCKSCOUT: UniqueNameSchema2.optional(),
|
|
62580
62667
|
SETTLEMINT_BLOCKSCOUT_GRAPHQL_ENDPOINT: UrlSchema2.optional(),
|
|
62581
62668
|
SETTLEMINT_BLOCKSCOUT_UI_ENDPOINT: UrlSchema2.optional(),
|
|
62582
|
-
SETTLEMINT_NEW_PROJECT_NAME: z.string().optional()
|
|
62669
|
+
SETTLEMINT_NEW_PROJECT_NAME: z.string().optional(),
|
|
62670
|
+
SETTLEMINT_LOG_LEVEL: z.enum(["debug", "info", "warn", "error", "none"]).default("warn")
|
|
62583
62671
|
});
|
|
62584
62672
|
var DotEnvSchemaPartial2 = DotEnvSchema2.partial();
|
|
62585
62673
|
var IdSchema2 = z.union([
|
|
@@ -62606,7 +62694,7 @@ var {
|
|
|
62606
62694
|
var package_default = {
|
|
62607
62695
|
name: "@settlemint/sdk-mcp",
|
|
62608
62696
|
description: "MCP interface for SettleMint SDK, providing development tools and project management capabilities",
|
|
62609
|
-
version: "2.
|
|
62697
|
+
version: "2.1.1-main25da2665",
|
|
62610
62698
|
type: "module",
|
|
62611
62699
|
private: false,
|
|
62612
62700
|
license: "FSL-1.1-MIT",
|
|
@@ -62645,11 +62733,11 @@ var package_default = {
|
|
|
62645
62733
|
prepack: "cp ../../LICENSE ."
|
|
62646
62734
|
},
|
|
62647
62735
|
dependencies: {
|
|
62648
|
-
"@graphql-tools/load": "8.0
|
|
62736
|
+
"@graphql-tools/load": "8.1.0",
|
|
62649
62737
|
"@graphql-tools/url-loader": "8.0.31",
|
|
62650
|
-
"@modelcontextprotocol/sdk": "1.
|
|
62651
|
-
"@settlemint/sdk-js": "2.
|
|
62652
|
-
"@settlemint/sdk-utils": "2.
|
|
62738
|
+
"@modelcontextprotocol/sdk": "1.9.0",
|
|
62739
|
+
"@settlemint/sdk-js": "2.1.1-main25da2665",
|
|
62740
|
+
"@settlemint/sdk-utils": "2.1.1-main25da2665",
|
|
62653
62741
|
"@commander-js/extra-typings": "11.1.0",
|
|
62654
62742
|
commander: "11.1.0",
|
|
62655
62743
|
zod: "3.24.2"
|
|
@@ -63816,7 +63904,7 @@ async function fetchWithRetry(input, init, maxRetries = 5, initialSleepTime = 30
|
|
|
63816
63904
|
|
|
63817
63905
|
// ../../node_modules/environment/index.js
|
|
63818
63906
|
var isBrowser = globalThis.window?.document !== undefined;
|
|
63819
|
-
var
|
|
63907
|
+
var isNode2 = globalThis.process?.versions?.node !== undefined;
|
|
63820
63908
|
var isBun = globalThis.process?.versions?.bun !== undefined;
|
|
63821
63909
|
var isDeno = globalThis.Deno?.version?.deno !== undefined;
|
|
63822
63910
|
var isElectron = globalThis.process?.versions?.electron !== undefined;
|
|
@@ -68071,4 +68159,4 @@ await main().catch((error2) => {
|
|
|
68071
68159
|
process.exit(1);
|
|
68072
68160
|
});
|
|
68073
68161
|
|
|
68074
|
-
//# debugId=
|
|
68162
|
+
//# debugId=EBE19BD13C3ED8B864756E2164756E21
|