@mastra/mcp-docs-server 1.3.8-alpha.0 → 1.3.8-alpha.3

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.
@@ -61,6 +61,8 @@ The first `execute` parameter is the validated value from `inputSchema`. Destruc
61
61
 
62
62
  **requireApproval** (`boolean`): When true, the tool requires explicit approval before execution. The agent will emit a tool-call-approval chunk and pause until approved or declined.
63
63
 
64
+ **beforeApproval** (`(input, context) => void | { proceed: false; output: unknown } | Promise<...>`): Runs before the approval gate for calls that require approval, receiving the input validated against inputSchema (defaults applied) and a context with toolCallId, toolName, requestContext, and workspace. Return { proceed: false, output } to reject the call: the agent does not pause for approval, execute is not called, and output is returned to the model as the tool result. Return nothing to continue to the approval gate. Not run when the input fails inputSchema validation (execute reports the validation error after approval) or when resuming after an approval decision. If the hook throws, the error is logged and the call proceeds to the approval gate, so keep validating inside execute as well.
65
+
64
66
  **mcp** (`MCPToolProperties`): MCP-specific properties for tools exposed via Model Context Protocol. Includes annotations (tool behavior hints like title, readOnlyHint, destructiveHint, idempotentHint, openWorldHint) and \_meta (arbitrary metadata passed through to MCP clients).
65
67
 
66
68
  **requestContextSchema** (`StandardJSONSchemaV1`): A Standard JSON Schema for validating request context values. When provided, the context is validated before execute() runs, returning an error object if validation fails.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mastra/mcp-docs-server",
3
- "version": "1.3.8-alpha.0",
3
+ "version": "1.3.8-alpha.3",
4
4
  "description": "MCP server for accessing Mastra.ai documentation, changelogs, and news.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -26,8 +26,8 @@
26
26
  "@mastra/mcp-legacy": "npm:@mastra/mcp@^1.18.0",
27
27
  "local-pkg": "^1.1.2",
28
28
  "zod": "^4.6.4",
29
- "@mastra/core": "1.78.0-alpha.0",
30
- "@mastra/mcp": "^2.4.0"
29
+ "@mastra/mcp": "^2.4.1-alpha.0",
30
+ "@mastra/core": "1.78.0-alpha.2"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@hono/node-server": "^2.0.0",
@@ -43,9 +43,9 @@
43
43
  "tsx": "^4.23.1",
44
44
  "typescript": "^7.0.2",
45
45
  "vitest": "4.1.11",
46
+ "@mastra/core": "1.78.0-alpha.2",
46
47
  "@internal/types-builder": "0.0.118",
47
- "@internal/lint": "0.0.143",
48
- "@mastra/core": "1.78.0-alpha.0"
48
+ "@internal/lint": "0.0.143"
49
49
  },
50
50
  "homepage": "https://mastra.ai",
51
51
  "repository": {