@settlemint/sdk-mcp 2.1.3 → 2.1.4-prc6365e9d
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 +177 -36
- package/dist/mcp.js.map +5 -5
- package/package.json +4 -4
package/dist/mcp.js
CHANGED
|
@@ -54595,14 +54595,17 @@ var JSONRPCRequestSchema = z.object({
|
|
|
54595
54595
|
jsonrpc: z.literal(JSONRPC_VERSION),
|
|
54596
54596
|
id: RequestIdSchema
|
|
54597
54597
|
}).merge(RequestSchema).strict();
|
|
54598
|
+
var isJSONRPCRequest = (value) => JSONRPCRequestSchema.safeParse(value).success;
|
|
54598
54599
|
var JSONRPCNotificationSchema = z.object({
|
|
54599
54600
|
jsonrpc: z.literal(JSONRPC_VERSION)
|
|
54600
54601
|
}).merge(NotificationSchema).strict();
|
|
54602
|
+
var isJSONRPCNotification = (value) => JSONRPCNotificationSchema.safeParse(value).success;
|
|
54601
54603
|
var JSONRPCResponseSchema = z.object({
|
|
54602
54604
|
jsonrpc: z.literal(JSONRPC_VERSION),
|
|
54603
54605
|
id: RequestIdSchema,
|
|
54604
54606
|
result: ResultSchema
|
|
54605
54607
|
}).strict();
|
|
54608
|
+
var isJSONRPCResponse = (value) => JSONRPCResponseSchema.safeParse(value).success;
|
|
54606
54609
|
var ErrorCode;
|
|
54607
54610
|
(function(ErrorCode2) {
|
|
54608
54611
|
ErrorCode2[ErrorCode2["ConnectionClosed"] = -32000] = "ConnectionClosed";
|
|
@@ -54622,6 +54625,7 @@ var JSONRPCErrorSchema = z.object({
|
|
|
54622
54625
|
data: z.optional(z.unknown())
|
|
54623
54626
|
})
|
|
54624
54627
|
}).strict();
|
|
54628
|
+
var isJSONRPCError = (value) => JSONRPCErrorSchema.safeParse(value).success;
|
|
54625
54629
|
var JSONRPCMessageSchema = z.union([
|
|
54626
54630
|
JSONRPCRequestSchema,
|
|
54627
54631
|
JSONRPCNotificationSchema,
|
|
@@ -55072,13 +55076,15 @@ class Protocol {
|
|
|
55072
55076
|
this._transport.onerror = (error) => {
|
|
55073
55077
|
this._onerror(error);
|
|
55074
55078
|
};
|
|
55075
|
-
this._transport.onmessage = (message) => {
|
|
55076
|
-
if (
|
|
55079
|
+
this._transport.onmessage = (message, extra) => {
|
|
55080
|
+
if (isJSONRPCResponse(message) || isJSONRPCError(message)) {
|
|
55077
55081
|
this._onresponse(message);
|
|
55078
|
-
} else if (
|
|
55079
|
-
this._onrequest(message);
|
|
55080
|
-
} else {
|
|
55082
|
+
} else if (isJSONRPCRequest(message)) {
|
|
55083
|
+
this._onrequest(message, extra);
|
|
55084
|
+
} else if (isJSONRPCNotification(message)) {
|
|
55081
55085
|
this._onnotification(message);
|
|
55086
|
+
} else {
|
|
55087
|
+
this._onerror(new Error(`Unknown message type: ${JSON.stringify(message)}`));
|
|
55082
55088
|
}
|
|
55083
55089
|
};
|
|
55084
55090
|
await this._transport.start();
|
|
@@ -55107,7 +55113,7 @@ class Protocol {
|
|
|
55107
55113
|
}
|
|
55108
55114
|
Promise.resolve().then(() => handler(notification)).catch((error) => this._onerror(new Error(`Uncaught error in notification handler: ${error}`)));
|
|
55109
55115
|
}
|
|
55110
|
-
_onrequest(request) {
|
|
55116
|
+
_onrequest(request, extra) {
|
|
55111
55117
|
var _a, _b, _c;
|
|
55112
55118
|
const handler = (_a = this._requestHandlers.get(request.method)) !== null && _a !== undefined ? _a : this.fallbackRequestHandler;
|
|
55113
55119
|
if (handler === undefined) {
|
|
@@ -55123,11 +55129,14 @@ class Protocol {
|
|
|
55123
55129
|
}
|
|
55124
55130
|
const abortController = new AbortController;
|
|
55125
55131
|
this._requestHandlerAbortControllers.set(request.id, abortController);
|
|
55126
|
-
const
|
|
55132
|
+
const fullExtra = {
|
|
55127
55133
|
signal: abortController.signal,
|
|
55128
|
-
sessionId: (_c = this._transport) === null || _c === undefined ? undefined : _c.sessionId
|
|
55134
|
+
sessionId: (_c = this._transport) === null || _c === undefined ? undefined : _c.sessionId,
|
|
55135
|
+
sendNotification: (notification) => this.notification(notification, { relatedRequestId: request.id }),
|
|
55136
|
+
sendRequest: (r, resultSchema, options) => this.request(r, resultSchema, { ...options, relatedRequestId: request.id }),
|
|
55137
|
+
authInfo: extra === null || extra === undefined ? undefined : extra.authInfo
|
|
55129
55138
|
};
|
|
55130
|
-
Promise.resolve().then(() => handler(request,
|
|
55139
|
+
Promise.resolve().then(() => handler(request, fullExtra)).then((result) => {
|
|
55131
55140
|
var _a2;
|
|
55132
55141
|
if (abortController.signal.aborted) {
|
|
55133
55142
|
return;
|
|
@@ -55184,7 +55193,7 @@ class Protocol {
|
|
|
55184
55193
|
this._responseHandlers.delete(messageId);
|
|
55185
55194
|
this._progressHandlers.delete(messageId);
|
|
55186
55195
|
this._cleanupTimeout(messageId);
|
|
55187
|
-
if (
|
|
55196
|
+
if (isJSONRPCResponse(response)) {
|
|
55188
55197
|
handler(response);
|
|
55189
55198
|
} else {
|
|
55190
55199
|
const error = new McpError(response.error.code, response.error.message, response.error.data);
|
|
@@ -55199,6 +55208,7 @@ class Protocol {
|
|
|
55199
55208
|
await ((_a = this._transport) === null || _a === undefined ? undefined : _a.close());
|
|
55200
55209
|
}
|
|
55201
55210
|
request(request, resultSchema, options) {
|
|
55211
|
+
const { relatedRequestId, resumptionToken, onresumptiontoken } = options !== null && options !== undefined ? options : {};
|
|
55202
55212
|
return new Promise((resolve, reject2) => {
|
|
55203
55213
|
var _a, _b, _c, _d, _e;
|
|
55204
55214
|
if (!this._transport) {
|
|
@@ -55234,7 +55244,7 @@ class Protocol {
|
|
|
55234
55244
|
requestId: messageId,
|
|
55235
55245
|
reason: String(reason)
|
|
55236
55246
|
}
|
|
55237
|
-
}).catch((error) => this._onerror(new Error(`Failed to send cancellation: ${error}`)));
|
|
55247
|
+
}, { relatedRequestId, resumptionToken, onresumptiontoken }).catch((error) => this._onerror(new Error(`Failed to send cancellation: ${error}`)));
|
|
55238
55248
|
reject2(reason);
|
|
55239
55249
|
};
|
|
55240
55250
|
this._responseHandlers.set(messageId, (response) => {
|
|
@@ -55259,13 +55269,13 @@ class Protocol {
|
|
|
55259
55269
|
const timeout = (_d = options === null || options === undefined ? undefined : options.timeout) !== null && _d !== undefined ? _d : DEFAULT_REQUEST_TIMEOUT_MSEC;
|
|
55260
55270
|
const timeoutHandler = () => cancel(new McpError(ErrorCode.RequestTimeout, "Request timed out", { timeout }));
|
|
55261
55271
|
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);
|
|
55262
|
-
this._transport.send(jsonrpcRequest).catch((error) => {
|
|
55272
|
+
this._transport.send(jsonrpcRequest, { relatedRequestId, resumptionToken, onresumptiontoken }).catch((error) => {
|
|
55263
55273
|
this._cleanupTimeout(messageId);
|
|
55264
55274
|
reject2(error);
|
|
55265
55275
|
});
|
|
55266
55276
|
});
|
|
55267
55277
|
}
|
|
55268
|
-
async notification(notification) {
|
|
55278
|
+
async notification(notification, options) {
|
|
55269
55279
|
if (!this._transport) {
|
|
55270
55280
|
throw new Error("Not connected");
|
|
55271
55281
|
}
|
|
@@ -55274,12 +55284,14 @@ class Protocol {
|
|
|
55274
55284
|
...notification,
|
|
55275
55285
|
jsonrpc: "2.0"
|
|
55276
55286
|
};
|
|
55277
|
-
await this._transport.send(jsonrpcNotification);
|
|
55287
|
+
await this._transport.send(jsonrpcNotification, options);
|
|
55278
55288
|
}
|
|
55279
55289
|
setRequestHandler(requestSchema, handler) {
|
|
55280
55290
|
const method = requestSchema.shape.method.value;
|
|
55281
55291
|
this.assertRequestHandlerCapability(method);
|
|
55282
|
-
this._requestHandlers.set(method, (request, extra) =>
|
|
55292
|
+
this._requestHandlers.set(method, (request, extra) => {
|
|
55293
|
+
return Promise.resolve(handler(requestSchema.parse(request), extra));
|
|
55294
|
+
});
|
|
55283
55295
|
}
|
|
55284
55296
|
removeRequestHandler(method) {
|
|
55285
55297
|
this._requestHandlers.delete(method);
|
|
@@ -56741,10 +56753,12 @@ class McpServer {
|
|
|
56741
56753
|
this.server.assertCanSetRequestHandler(ListToolsRequestSchema.shape.method.value);
|
|
56742
56754
|
this.server.assertCanSetRequestHandler(CallToolRequestSchema.shape.method.value);
|
|
56743
56755
|
this.server.registerCapabilities({
|
|
56744
|
-
tools: {
|
|
56756
|
+
tools: {
|
|
56757
|
+
listChanged: true
|
|
56758
|
+
}
|
|
56745
56759
|
});
|
|
56746
56760
|
this.server.setRequestHandler(ListToolsRequestSchema, () => ({
|
|
56747
|
-
tools: Object.entries(this._registeredTools).map(([name, tool]) => {
|
|
56761
|
+
tools: Object.entries(this._registeredTools).filter(([, tool]) => tool.enabled).map(([name, tool]) => {
|
|
56748
56762
|
return {
|
|
56749
56763
|
name,
|
|
56750
56764
|
description: tool.description,
|
|
@@ -56759,6 +56773,9 @@ class McpServer {
|
|
|
56759
56773
|
if (!tool) {
|
|
56760
56774
|
throw new McpError(ErrorCode.InvalidParams, `Tool ${request.params.name} not found`);
|
|
56761
56775
|
}
|
|
56776
|
+
if (!tool.enabled) {
|
|
56777
|
+
throw new McpError(ErrorCode.InvalidParams, `Tool ${request.params.name} disabled`);
|
|
56778
|
+
}
|
|
56762
56779
|
if (tool.inputSchema) {
|
|
56763
56780
|
const parseResult = await tool.inputSchema.safeParseAsync(request.params.arguments);
|
|
56764
56781
|
if (!parseResult.success) {
|
|
@@ -56818,7 +56835,10 @@ class McpServer {
|
|
|
56818
56835
|
async handlePromptCompletion(request, ref) {
|
|
56819
56836
|
const prompt = this._registeredPrompts[ref.name];
|
|
56820
56837
|
if (!prompt) {
|
|
56821
|
-
throw new McpError(ErrorCode.InvalidParams, `Prompt ${
|
|
56838
|
+
throw new McpError(ErrorCode.InvalidParams, `Prompt ${ref.name} not found`);
|
|
56839
|
+
}
|
|
56840
|
+
if (!prompt.enabled) {
|
|
56841
|
+
throw new McpError(ErrorCode.InvalidParams, `Prompt ${ref.name} disabled`);
|
|
56822
56842
|
}
|
|
56823
56843
|
if (!prompt.argsSchema) {
|
|
56824
56844
|
return EMPTY_COMPLETION_RESULT;
|
|
@@ -56854,10 +56874,12 @@ class McpServer {
|
|
|
56854
56874
|
this.server.assertCanSetRequestHandler(ListResourceTemplatesRequestSchema.shape.method.value);
|
|
56855
56875
|
this.server.assertCanSetRequestHandler(ReadResourceRequestSchema.shape.method.value);
|
|
56856
56876
|
this.server.registerCapabilities({
|
|
56857
|
-
resources: {
|
|
56877
|
+
resources: {
|
|
56878
|
+
listChanged: true
|
|
56879
|
+
}
|
|
56858
56880
|
});
|
|
56859
56881
|
this.server.setRequestHandler(ListResourcesRequestSchema, async (request, extra) => {
|
|
56860
|
-
const resources = Object.entries(this._registeredResources).map(([uri, resource]) => ({
|
|
56882
|
+
const resources = Object.entries(this._registeredResources).filter(([_, resource]) => resource.enabled).map(([uri, resource]) => ({
|
|
56861
56883
|
uri,
|
|
56862
56884
|
name: resource.name,
|
|
56863
56885
|
...resource.metadata
|
|
@@ -56889,6 +56911,9 @@ class McpServer {
|
|
|
56889
56911
|
const uri = new URL(request.params.uri);
|
|
56890
56912
|
const resource = this._registeredResources[uri.toString()];
|
|
56891
56913
|
if (resource) {
|
|
56914
|
+
if (!resource.enabled) {
|
|
56915
|
+
throw new McpError(ErrorCode.InvalidParams, `Resource ${uri} disabled`);
|
|
56916
|
+
}
|
|
56892
56917
|
return resource.readCallback(uri, extra);
|
|
56893
56918
|
}
|
|
56894
56919
|
for (const template of Object.values(this._registeredResourceTemplates)) {
|
|
@@ -56909,10 +56934,12 @@ class McpServer {
|
|
|
56909
56934
|
this.server.assertCanSetRequestHandler(ListPromptsRequestSchema.shape.method.value);
|
|
56910
56935
|
this.server.assertCanSetRequestHandler(GetPromptRequestSchema.shape.method.value);
|
|
56911
56936
|
this.server.registerCapabilities({
|
|
56912
|
-
prompts: {
|
|
56937
|
+
prompts: {
|
|
56938
|
+
listChanged: true
|
|
56939
|
+
}
|
|
56913
56940
|
});
|
|
56914
56941
|
this.server.setRequestHandler(ListPromptsRequestSchema, () => ({
|
|
56915
|
-
prompts: Object.entries(this._registeredPrompts).map(([name, prompt]) => {
|
|
56942
|
+
prompts: Object.entries(this._registeredPrompts).filter(([, prompt]) => prompt.enabled).map(([name, prompt]) => {
|
|
56916
56943
|
return {
|
|
56917
56944
|
name,
|
|
56918
56945
|
description: prompt.description,
|
|
@@ -56925,6 +56952,9 @@ class McpServer {
|
|
|
56925
56952
|
if (!prompt) {
|
|
56926
56953
|
throw new McpError(ErrorCode.InvalidParams, `Prompt ${request.params.name} not found`);
|
|
56927
56954
|
}
|
|
56955
|
+
if (!prompt.enabled) {
|
|
56956
|
+
throw new McpError(ErrorCode.InvalidParams, `Prompt ${request.params.name} disabled`);
|
|
56957
|
+
}
|
|
56928
56958
|
if (prompt.argsSchema) {
|
|
56929
56959
|
const parseResult = await prompt.argsSchema.safeParseAsync(request.params.arguments);
|
|
56930
56960
|
if (!parseResult.success) {
|
|
@@ -56951,22 +56981,69 @@ class McpServer {
|
|
|
56951
56981
|
if (this._registeredResources[uriOrTemplate]) {
|
|
56952
56982
|
throw new Error(`Resource ${uriOrTemplate} is already registered`);
|
|
56953
56983
|
}
|
|
56954
|
-
|
|
56984
|
+
const registeredResource = {
|
|
56955
56985
|
name,
|
|
56956
56986
|
metadata,
|
|
56957
|
-
readCallback
|
|
56987
|
+
readCallback,
|
|
56988
|
+
enabled: true,
|
|
56989
|
+
disable: () => registeredResource.update({ enabled: false }),
|
|
56990
|
+
enable: () => registeredResource.update({ enabled: true }),
|
|
56991
|
+
remove: () => registeredResource.update({ uri: null }),
|
|
56992
|
+
update: (updates) => {
|
|
56993
|
+
if (typeof updates.uri !== "undefined" && updates.uri !== uriOrTemplate) {
|
|
56994
|
+
delete this._registeredResources[uriOrTemplate];
|
|
56995
|
+
if (updates.uri)
|
|
56996
|
+
this._registeredResources[updates.uri] = registeredResource;
|
|
56997
|
+
}
|
|
56998
|
+
if (typeof updates.name !== "undefined")
|
|
56999
|
+
registeredResource.name = updates.name;
|
|
57000
|
+
if (typeof updates.metadata !== "undefined")
|
|
57001
|
+
registeredResource.metadata = updates.metadata;
|
|
57002
|
+
if (typeof updates.callback !== "undefined")
|
|
57003
|
+
registeredResource.readCallback = updates.callback;
|
|
57004
|
+
if (typeof updates.enabled !== "undefined")
|
|
57005
|
+
registeredResource.enabled = updates.enabled;
|
|
57006
|
+
this.sendResourceListChanged();
|
|
57007
|
+
}
|
|
56958
57008
|
};
|
|
57009
|
+
this._registeredResources[uriOrTemplate] = registeredResource;
|
|
57010
|
+
this.setResourceRequestHandlers();
|
|
57011
|
+
this.sendResourceListChanged();
|
|
57012
|
+
return registeredResource;
|
|
56959
57013
|
} else {
|
|
56960
57014
|
if (this._registeredResourceTemplates[name]) {
|
|
56961
57015
|
throw new Error(`Resource template ${name} is already registered`);
|
|
56962
57016
|
}
|
|
56963
|
-
|
|
57017
|
+
const registeredResourceTemplate = {
|
|
56964
57018
|
resourceTemplate: uriOrTemplate,
|
|
56965
57019
|
metadata,
|
|
56966
|
-
readCallback
|
|
57020
|
+
readCallback,
|
|
57021
|
+
enabled: true,
|
|
57022
|
+
disable: () => registeredResourceTemplate.update({ enabled: false }),
|
|
57023
|
+
enable: () => registeredResourceTemplate.update({ enabled: true }),
|
|
57024
|
+
remove: () => registeredResourceTemplate.update({ name: null }),
|
|
57025
|
+
update: (updates) => {
|
|
57026
|
+
if (typeof updates.name !== "undefined" && updates.name !== name) {
|
|
57027
|
+
delete this._registeredResourceTemplates[name];
|
|
57028
|
+
if (updates.name)
|
|
57029
|
+
this._registeredResourceTemplates[updates.name] = registeredResourceTemplate;
|
|
57030
|
+
}
|
|
57031
|
+
if (typeof updates.template !== "undefined")
|
|
57032
|
+
registeredResourceTemplate.resourceTemplate = updates.template;
|
|
57033
|
+
if (typeof updates.metadata !== "undefined")
|
|
57034
|
+
registeredResourceTemplate.metadata = updates.metadata;
|
|
57035
|
+
if (typeof updates.callback !== "undefined")
|
|
57036
|
+
registeredResourceTemplate.readCallback = updates.callback;
|
|
57037
|
+
if (typeof updates.enabled !== "undefined")
|
|
57038
|
+
registeredResourceTemplate.enabled = updates.enabled;
|
|
57039
|
+
this.sendResourceListChanged();
|
|
57040
|
+
}
|
|
56967
57041
|
};
|
|
57042
|
+
this._registeredResourceTemplates[name] = registeredResourceTemplate;
|
|
57043
|
+
this.setResourceRequestHandlers();
|
|
57044
|
+
this.sendResourceListChanged();
|
|
57045
|
+
return registeredResourceTemplate;
|
|
56968
57046
|
}
|
|
56969
|
-
this.setResourceRequestHandlers();
|
|
56970
57047
|
}
|
|
56971
57048
|
tool(name, ...rest) {
|
|
56972
57049
|
if (this._registeredTools[name]) {
|
|
@@ -56981,12 +57058,35 @@ class McpServer {
|
|
|
56981
57058
|
paramsSchema = rest.shift();
|
|
56982
57059
|
}
|
|
56983
57060
|
const cb = rest[0];
|
|
56984
|
-
|
|
57061
|
+
const registeredTool = {
|
|
56985
57062
|
description,
|
|
56986
57063
|
inputSchema: paramsSchema === undefined ? undefined : z.object(paramsSchema),
|
|
56987
|
-
callback: cb
|
|
57064
|
+
callback: cb,
|
|
57065
|
+
enabled: true,
|
|
57066
|
+
disable: () => registeredTool.update({ enabled: false }),
|
|
57067
|
+
enable: () => registeredTool.update({ enabled: true }),
|
|
57068
|
+
remove: () => registeredTool.update({ name: null }),
|
|
57069
|
+
update: (updates) => {
|
|
57070
|
+
if (typeof updates.name !== "undefined" && updates.name !== name) {
|
|
57071
|
+
delete this._registeredTools[name];
|
|
57072
|
+
if (updates.name)
|
|
57073
|
+
this._registeredTools[updates.name] = registeredTool;
|
|
57074
|
+
}
|
|
57075
|
+
if (typeof updates.description !== "undefined")
|
|
57076
|
+
registeredTool.description = updates.description;
|
|
57077
|
+
if (typeof updates.paramsSchema !== "undefined")
|
|
57078
|
+
registeredTool.inputSchema = z.object(updates.paramsSchema);
|
|
57079
|
+
if (typeof updates.callback !== "undefined")
|
|
57080
|
+
registeredTool.callback = updates.callback;
|
|
57081
|
+
if (typeof updates.enabled !== "undefined")
|
|
57082
|
+
registeredTool.enabled = updates.enabled;
|
|
57083
|
+
this.sendToolListChanged();
|
|
57084
|
+
}
|
|
56988
57085
|
};
|
|
57086
|
+
this._registeredTools[name] = registeredTool;
|
|
56989
57087
|
this.setToolRequestHandlers();
|
|
57088
|
+
this.sendToolListChanged();
|
|
57089
|
+
return registeredTool;
|
|
56990
57090
|
}
|
|
56991
57091
|
prompt(name, ...rest) {
|
|
56992
57092
|
if (this._registeredPrompts[name]) {
|
|
@@ -57001,12 +57101,53 @@ class McpServer {
|
|
|
57001
57101
|
argsSchema = rest.shift();
|
|
57002
57102
|
}
|
|
57003
57103
|
const cb = rest[0];
|
|
57004
|
-
|
|
57104
|
+
const registeredPrompt = {
|
|
57005
57105
|
description,
|
|
57006
57106
|
argsSchema: argsSchema === undefined ? undefined : z.object(argsSchema),
|
|
57007
|
-
callback: cb
|
|
57107
|
+
callback: cb,
|
|
57108
|
+
enabled: true,
|
|
57109
|
+
disable: () => registeredPrompt.update({ enabled: false }),
|
|
57110
|
+
enable: () => registeredPrompt.update({ enabled: true }),
|
|
57111
|
+
remove: () => registeredPrompt.update({ name: null }),
|
|
57112
|
+
update: (updates) => {
|
|
57113
|
+
if (typeof updates.name !== "undefined" && updates.name !== name) {
|
|
57114
|
+
delete this._registeredPrompts[name];
|
|
57115
|
+
if (updates.name)
|
|
57116
|
+
this._registeredPrompts[updates.name] = registeredPrompt;
|
|
57117
|
+
}
|
|
57118
|
+
if (typeof updates.description !== "undefined")
|
|
57119
|
+
registeredPrompt.description = updates.description;
|
|
57120
|
+
if (typeof updates.argsSchema !== "undefined")
|
|
57121
|
+
registeredPrompt.argsSchema = z.object(updates.argsSchema);
|
|
57122
|
+
if (typeof updates.callback !== "undefined")
|
|
57123
|
+
registeredPrompt.callback = updates.callback;
|
|
57124
|
+
if (typeof updates.enabled !== "undefined")
|
|
57125
|
+
registeredPrompt.enabled = updates.enabled;
|
|
57126
|
+
this.sendPromptListChanged();
|
|
57127
|
+
}
|
|
57008
57128
|
};
|
|
57129
|
+
this._registeredPrompts[name] = registeredPrompt;
|
|
57009
57130
|
this.setPromptRequestHandlers();
|
|
57131
|
+
this.sendPromptListChanged();
|
|
57132
|
+
return registeredPrompt;
|
|
57133
|
+
}
|
|
57134
|
+
isConnected() {
|
|
57135
|
+
return this.server.transport !== undefined;
|
|
57136
|
+
}
|
|
57137
|
+
sendResourceListChanged() {
|
|
57138
|
+
if (this.isConnected()) {
|
|
57139
|
+
this.server.sendResourceListChanged();
|
|
57140
|
+
}
|
|
57141
|
+
}
|
|
57142
|
+
sendToolListChanged() {
|
|
57143
|
+
if (this.isConnected()) {
|
|
57144
|
+
this.server.sendToolListChanged();
|
|
57145
|
+
}
|
|
57146
|
+
}
|
|
57147
|
+
sendPromptListChanged() {
|
|
57148
|
+
if (this.isConnected()) {
|
|
57149
|
+
this.server.sendPromptListChanged();
|
|
57150
|
+
}
|
|
57010
57151
|
}
|
|
57011
57152
|
}
|
|
57012
57153
|
var EMPTY_OBJECT_JSON_SCHEMA = {
|
|
@@ -62694,7 +62835,7 @@ var {
|
|
|
62694
62835
|
var package_default = {
|
|
62695
62836
|
name: "@settlemint/sdk-mcp",
|
|
62696
62837
|
description: "MCP interface for SettleMint SDK, providing development tools and project management capabilities",
|
|
62697
|
-
version: "2.1.
|
|
62838
|
+
version: "2.1.4-prc6365e9d",
|
|
62698
62839
|
type: "module",
|
|
62699
62840
|
private: false,
|
|
62700
62841
|
license: "FSL-1.1-MIT",
|
|
@@ -62735,9 +62876,9 @@ var package_default = {
|
|
|
62735
62876
|
dependencies: {
|
|
62736
62877
|
"@graphql-tools/load": "8.1.0",
|
|
62737
62878
|
"@graphql-tools/url-loader": "8.0.31",
|
|
62738
|
-
"@modelcontextprotocol/sdk": "1.
|
|
62739
|
-
"@settlemint/sdk-js": "2.1.
|
|
62740
|
-
"@settlemint/sdk-utils": "2.1.
|
|
62879
|
+
"@modelcontextprotocol/sdk": "1.10.1",
|
|
62880
|
+
"@settlemint/sdk-js": "2.1.4-prc6365e9d",
|
|
62881
|
+
"@settlemint/sdk-utils": "2.1.4-prc6365e9d",
|
|
62741
62882
|
"@commander-js/extra-typings": "11.1.0",
|
|
62742
62883
|
commander: "11.1.0",
|
|
62743
62884
|
zod: "3.24.2"
|
|
@@ -68155,4 +68296,4 @@ await main().catch((error2) => {
|
|
|
68155
68296
|
process.exit(1);
|
|
68156
68297
|
});
|
|
68157
68298
|
|
|
68158
|
-
//# debugId=
|
|
68299
|
+
//# debugId=7C4339983C39E3B264756E2164756E21
|