@whattio/mcp-server 1.0.0 → 1.0.2

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/build/index.js CHANGED
@@ -1,3 +1,4 @@
1
+ #!/usr/bin/env node
1
2
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
2
3
  import { server } from "./server.js";
3
4
  async function main() {
@@ -41,7 +41,7 @@ export const productTools = [
41
41
  },
42
42
  {
43
43
  name: "v2_show_product",
44
- description: "Get detailed information about a specific product",
44
+ description: "Get detailed information about a specific product. CRITICAL AI HINT ON PARTS: In whatt.io, 'parts' represents unique parts specific to an assembly. However, most assemblies rely heavily on 'linkedParts' (standardized spare parts/components) and 'linkedProducts' (sub-assemblies). You must check 'linkedParts' and 'linkedProducts' when analyzing a product's components.",
45
45
  inputSchema: {
46
46
  type: "object",
47
47
  properties: {
@@ -50,7 +50,11 @@ export const productTools = [
50
50
  required: ["id"]
51
51
  },
52
52
  handler: async (args, apiClient) => {
53
- const response = await apiClient.get(`/api/v2/product/${args.id}/show`);
53
+ const response = await apiClient.get(`/api/v2/product/${args.id}/show`, {
54
+ params: {
55
+ with: 'linkedParts,linkedProducts,units,team.customFields'
56
+ }
57
+ });
54
58
  return response.data;
55
59
  }
56
60
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@whattio/mcp-server",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "The official Model Context Protocol (MCP) server for whatt.io",
5
5
  "main": "build/index.js",
6
6
  "bin": {
package/src/index.ts CHANGED
@@ -1,3 +1,4 @@
1
+ #!/usr/bin/env node
1
2
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
2
3
  import { server } from "./server.js";
3
4
 
@@ -43,7 +43,7 @@ export const productTools: McpTool[] = [
43
43
  },
44
44
  {
45
45
  name: "v2_show_product",
46
- description: "Get detailed information about a specific product",
46
+ description: "Get detailed information about a specific product. CRITICAL AI HINT ON PARTS: In whatt.io, 'parts' represents unique parts specific to an assembly. However, most assemblies rely heavily on 'linkedParts' (standardized spare parts/components) and 'linkedProducts' (sub-assemblies). You must check 'linkedParts' and 'linkedProducts' when analyzing a product's components.",
47
47
  inputSchema: {
48
48
  type: "object",
49
49
  properties: {
@@ -52,7 +52,11 @@ export const productTools: McpTool[] = [
52
52
  required: ["id"]
53
53
  },
54
54
  handler: async (args, apiClient) => {
55
- const response = await apiClient.get(`/api/v2/product/${args.id}/show`);
55
+ const response = await apiClient.get(`/api/v2/product/${args.id}/show`, {
56
+ params: {
57
+ with: 'linkedParts,linkedProducts,units,team.customFields'
58
+ }
59
+ });
56
60
  return response.data;
57
61
  }
58
62
  },