@tiwater/office-mcp 0.15.2 → 0.15.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.
@@ -8,8 +8,9 @@ import { spawn } from 'node:child_process';
8
8
  const sharedDir = path.dirname(fileURLToPath(import.meta.url));
9
9
  export const repoRoot = path.resolve(sharedDir, '..', '..');
10
10
 
11
- export function createToolResult(payload) {
11
+ export function createToolResult(payload, { isError = false } = {}) {
12
12
  return {
13
+ ...(isError ? { isError: true } : {}),
13
14
  structuredContent: payload,
14
15
  content: [
15
16
  {
package/office/README.md CHANGED
@@ -27,6 +27,9 @@ Each mutation tool fixes its provider operation type. Callers submit only the
27
27
  coordinates and values for that action, so they cannot provide an arbitrary
28
28
  operation discriminator or a multi-action plan language. A call may batch
29
29
  multiple changes only when every change has the same action kind.
30
+ When a completed mutation receipt reports `summary.pass=false`, the MCP result
31
+ also sets the standard `isError` field; consumers do not need a private failure
32
+ interpretation.
30
33
 
31
34
  Structural worksheet row deletion is exposed as `xlsx_delete_rows`. Each change
32
35
  contains only `sheet`, `startRow`, and `count`; unsupported dependent workbook
@@ -2,7 +2,7 @@
2
2
  "schema": "tiwater.office-provider-contract-manifest/v1",
3
3
  "provider": {
4
4
  "id": "@tiwater/office-mcp",
5
- "version": "0.15.2"
5
+ "version": "0.15.3"
6
6
  },
7
7
  "tools": [
8
8
  {
package/office/index.mjs CHANGED
@@ -382,7 +382,10 @@ function buildServer() {
382
382
  ...(tool.outputSchema ? { outputSchema: tool.outputSchema } : {}),
383
383
  ...(tool.annotations ? { annotations: tool.annotations } : {}),
384
384
  },
385
- async args => createToolResult(await tool.handler(args)),
385
+ async args => {
386
+ const payload = await tool.handler(args);
387
+ return createToolResult(payload, { isError: payload?.summary?.pass === false });
388
+ },
386
389
  );
387
390
  }
388
391
  return server;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tiwater/office-mcp",
3
- "version": "0.15.2",
3
+ "version": "0.15.3",
4
4
  "description": "Published MCP server for Tiwater Office document capabilities",
5
5
  "type": "module",
6
6
  "license": "MIT",