@mastra/mcp 1.17.0 → 1.17.1-alpha.0
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/CHANGELOG.md +9 -0
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/index.cjs +10 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +10 -4
- package/dist/index.js.map +1 -1
- package/dist/server/server.d.ts +1 -0
- package/dist/server/server.d.ts.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -27213,7 +27213,7 @@ var MCPServer = class extends MCPServerBase {
|
|
|
27213
27213
|
const toolSpec = {
|
|
27214
27214
|
name: tool.id || "unknown",
|
|
27215
27215
|
description: tool.description,
|
|
27216
|
-
inputSchema: this.
|
|
27216
|
+
inputSchema: this.convertInputSchema(tool.parameters)
|
|
27217
27217
|
};
|
|
27218
27218
|
if (tool.outputSchema) toolSpec.outputSchema = this.convertSchema(tool.outputSchema);
|
|
27219
27219
|
if (tool.mcp?.annotations) toolSpec.annotations = tool.mcp.annotations;
|
|
@@ -28485,6 +28485,12 @@ var MCPServer = class extends MCPServerBase {
|
|
|
28485
28485
|
}
|
|
28486
28486
|
return jsonSchema;
|
|
28487
28487
|
}
|
|
28488
|
+
convertInputSchema(schema) {
|
|
28489
|
+
return this.convertSchema(schema) ?? {
|
|
28490
|
+
type: "object",
|
|
28491
|
+
properties: {}
|
|
28492
|
+
};
|
|
28493
|
+
}
|
|
28488
28494
|
/**
|
|
28489
28495
|
* Gets a list of all tools provided by this MCP server with their schemas.
|
|
28490
28496
|
*
|
|
@@ -28508,7 +28514,7 @@ var MCPServer = class extends MCPServerBase {
|
|
|
28508
28514
|
id: toolId,
|
|
28509
28515
|
name: tool.id || toolId,
|
|
28510
28516
|
description: tool.description,
|
|
28511
|
-
inputSchema: this.
|
|
28517
|
+
inputSchema: this.convertInputSchema(tool.parameters),
|
|
28512
28518
|
outputSchema: this.convertSchema(tool.outputSchema),
|
|
28513
28519
|
toolType: tool.mcp?.toolType,
|
|
28514
28520
|
_meta: withMastraToolStrictMeta(tool.mcp?._meta, tool.strict)
|
|
@@ -28519,7 +28525,7 @@ var MCPServer = class extends MCPServerBase {
|
|
|
28519
28525
|
id: toolId,
|
|
28520
28526
|
name: tool.id || toolId,
|
|
28521
28527
|
description: tool.description,
|
|
28522
|
-
inputSchema: this.
|
|
28528
|
+
inputSchema: this.convertInputSchema(tool.parameters),
|
|
28523
28529
|
outputSchema: this.convertSchema(tool.outputSchema),
|
|
28524
28530
|
toolType: tool.mcp?.toolType,
|
|
28525
28531
|
_meta: withMastraToolStrictMeta(tool.mcp?._meta, tool.strict)
|
|
@@ -28559,7 +28565,7 @@ var MCPServer = class extends MCPServerBase {
|
|
|
28559
28565
|
return {
|
|
28560
28566
|
name: tool.id || toolId,
|
|
28561
28567
|
description: tool.description,
|
|
28562
|
-
inputSchema: this.
|
|
28568
|
+
inputSchema: this.convertInputSchema(tool.parameters),
|
|
28563
28569
|
outputSchema: this.convertSchema(tool.outputSchema),
|
|
28564
28570
|
toolType: tool.mcp?.toolType,
|
|
28565
28571
|
_meta: withMastraToolStrictMeta(tool.mcp?._meta, tool.strict)
|