Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

feat: search tool and call tool

Brad Barbineaee40b11641
diff --git a/apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysForm.tsx b/apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysForm.tsx
index 6d7908fdcb..9f8e033236 100644
--- a/apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysForm.tsx
+++ b/apps/erp/app/modules/settings/ui/ApiKeys/ApiKeysForm.tsx
@@ -190,7 +190,7 @@ function ApiKeyView({ apiKey, onClose }: ApiKeyViewProps) {
<Trans>You can only see this key once. Store it safely.</Trans>
</AlertTitle>
</Alert>
- <div>
+ <div className="flex flex-col gap-2 w-full">
<Label htmlFor="api-key">
<Trans>API Key</Trans>
</Label>
@@ -210,7 +210,7 @@ function ApiKeyView({ apiKey, onClose }: ApiKeyViewProps) {
</InputRightElement>
</InputGroup>
</div>
- <div>
+ <div className="flex flex-col gap-2 w-full">
<Label htmlFor="mcp-command">
<Trans>MCP Command</Trans>
</Label>
diff --git a/apps/erp/app/routes/api+/mcp+/_index.ts b/apps/erp/app/routes/api+/mcp+/_index.ts
index f3631eb96a..eb5e74bd8c 100644
--- a/apps/erp/app/routes/api+/mcp+/_index.ts
+++ b/apps/erp/app/routes/api+/mcp+/_index.ts
@@ -4,6 +4,12 @@ import type { ActionFunctionArgs } from "react-router";
import { createMcpServer } from "./lib/server";
export async function action({ request }: ActionFunctionArgs) {
+ console.log("[MCP] Received request:", {
+ method: request.method,
+ url: request.url,
+ headers: Object.fromEntries(request.headers.entries())
+ });
+
const authHeader = request.headers.get("Authorization");
const hasCarbonKey = request.headers.has("carbon-key");
@@ -12,9 +18,11 @@ export async function action({ request }: ActionFunctionArgs) {
const headers = new Headers(request.headers);
headers.set("carbon-key", token);
request = new Request(request, { headers });
+ console.log("[MCP] Added carbon-key header from Bearer token");
}
const { client, companyId, userId } = await requirePermissions(request, {});
+ console.log("[MCP] Auth successful:", { companyId, userId });
const server = createMcpServer({ client, companyId, userId });
const transport = new WebStandardStreamableHTTPServerTransport({
@@ -23,8 +31,21 @@ export async function action({ request }: ActionFunctionArgs) {
});
await server.connect(transport);
+ console.log("[MCP] Server connected");
+
+ const response = await transport.handleRequest(request);
+ console.log("[MCP] Response status:", response.status);
+
+ // Log response body for debugging
+ const clonedResponse = response.clone();
+ try {
+ const responseBody = await clonedResponse.text();
+ console.log("[MCP] Response body:", responseBody.substring(0, 500));
+ } catch (_e) {
+ console.log("[MCP] Could not read response body");
+ }
- return transport.handleRequest(request);
+ return response;
}
export async function loader() {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/direct-executor.ts b/apps/erp/app/routes/api+/mcp+/lib/direct-executor.ts
new file mode 100644
index 0000000000..7984b4e5a1
--- /dev/null
+++ b/apps/erp/app/routes/api+/mcp+/lib/direct-executor.ts
@@ -0,0 +1,300 @@
+// Direct executor for ERP functions without MCP protocol wrapper
+
+import type { Database } from "@carbon/database";
+import type { SupabaseClient } from "@supabase/supabase-js";
+import * as accountFunctions from "~/modules/account/account.service";
+import * as accountingFunctions from "~/modules/accounting/accounting.service";
+import * as documentsFunctions from "~/modules/documents/documents.service";
+import * as inventoryFunctions from "~/modules/inventory/inventory.service";
+import * as invoicingFunctions from "~/modules/invoicing/invoicing.service";
+import * as itemsFunctions from "~/modules/items/items.service";
+import * as peopleFunctions from "~/modules/people/people.service";
+import * as productionFunctions from "~/modules/production/production.service";
+import * as purchasingFunctions from "~/modules/purchasing/purchasing.service";
+import * as qualityFunctions from "~/modules/quality/quality.service";
+import * as resourcesFunctions from "~/modules/resources/resources.service";
+import * as salesFunctions from "~/modules/sales/sales.service";
+import * as settingsFunctions from "~/modules/settings/settings.service";
+import * as sharedFunctions from "~/modules/shared/shared.service";
+import * as usersFunctions from "~/modules/users/users.service";
+import { isMcpBlockedTool } from "./mcp-blocked-tools";
+
+// Combine all functions into a single registry
+const functionRegistry = {
+ account: accountFunctions,
+ accounting: accountingFunctions,
+ documents: documentsFunctions,
+ inventory: inventoryFunctions,
+ invoicing: invoicingFunctions,
+ items: itemsFunctions,
+ people: peopleFunctions,
+ production: productionFunctions,
+ purchasing: purchasingFunctions,
+ quality: qualityFunctions,
+ resources: resourcesFunctions,
+ sales: salesFunctions,
+ settings: settingsFunctions,
+ shared: sharedFunctions,
+ users: usersFunctions
+};
+
+export interface ExecutorContext {
+ client: SupabaseClient<Database>;
+ companyId: string;
+ userId: string;
+}
+
+export async function executeFunction(
+ functionName: string,
+ context: ExecutorContext,
+ args?: Record<string, any> | string
+) {
+ if (typeof args === "string") {
+ try {
+ args = args.trim().length > 0 ? JSON.parse(args) : {};
+ } catch {
+ return {
+ success: false,
+ error: "Invalid JSON arguments"
+ };
+ }
+ }
+ const normalizedArgs = args && typeof args === "object" ? args : undefined;
+
+ console.log("[DirectExecutor] Executing function:", functionName);
+ console.log(
+ "[DirectExecutor] Args:",
+ JSON.stringify(normalizedArgs, null, 2)
+ );
+ console.log("[DirectExecutor] Context:", {
+ companyId: context.companyId,
+ userId: context.userId
+ });
+
+ if (isMcpBlockedTool(functionName)) {
+ return {
+ success: false,
+ error: `Tool disabled: ${functionName} is not available via MCP.`
+ };
+ }
+
+ // Parse the function name to get module and function
+ const parts = functionName.split("_");
+ if (parts.length < 2) {
+ console.error(
+ "[DirectExecutor] Invalid function name format:",
+ functionName
+ );
+ throw new Error(`Invalid function name format: ${functionName}`);
+ }
+
+ const moduleName = parts[0];
+ const funcName = parts.slice(1).join("_");
+ console.log("[DirectExecutor] Module:", moduleName, "Function:", funcName);
+
+ // Get the module functions
+ const moduleFunctions =
+ functionRegistry[moduleName as keyof typeof functionRegistry];
+ if (!moduleFunctions) {
+ console.error("[DirectExecutor] Module not found:", moduleName);
+ console.log(
+ "[DirectExecutor] Available modules:",
+ Object.keys(functionRegistry)
+ );
+ throw new Error(`Module not found: ${moduleName}`);
+ }
+
+ // Get the specific function
+ const func = moduleFunctions[funcName as keyof typeof moduleFunctions];
+ if (!func || typeof func !== "function") {
+ console.error(
+ "[DirectExecutor] Function not found:",
+ funcName,
+ "in module",
+ moduleName
+ );
+ console.log(
+ "[DirectExecutor] Available functions in module:",
+ Object.keys(moduleFunctions)
+ );
+ throw new Error(`Function not found: ${funcName} in module ${moduleName}`);
+ }
+ console.log("[DirectExecutor] Function found successfully");
+
+ try {
+ // Get function parameter names by converting to string and parsing
+ const funcString = (func as Function).toString();
+ const paramMatch = funcString.match(/\(([^)]*)\)/);
+ const paramNames =
+ paramMatch?.[1]
+ ?.split(",")
+ ?.map((p: string) => p.trim().split(/[=\s]/)[0])
+ ?.filter((p: string) => p) || [];
+
+ console.log("[DirectExecutor] Function parameters:", paramNames);
+
+ // Build arguments array based on parameter names
+ const functionArgs: any[] = [];
+
+ for (const paramName of paramNames) {
+ if (paramName === "client") {
+ functionArgs.push(context.client);
+ console.log("[DirectExecutor] Added client to args");
+ } else if (paramName === "userId") {
+ const userIdValue = normalizedArgs?.userId || context.userId;
+ functionArgs.push(userIdValue);
+ console.log("[DirectExecutor] Added userId to args:", userIdValue);
+ } else if (paramName === "companyId") {
+ const companyIdValue = normalizedArgs?.companyId || context.companyId;
+ functionArgs.push(companyIdValue);
+ console.log(
+ "[DirectExecutor] Added companyId to args:",
+ companyIdValue
+ );
+ } else if (paramName === "args") {
+ // For 'args' parameter, pass the entire args object or a default
+ // This is the parameter that most service functions expect
+ const argsValue = normalizedArgs || {};
+ functionArgs.push(argsValue);
+ console.log(
+ "[DirectExecutor] Added args object:",
+ JSON.stringify(argsValue, null, 2)
+ );
+ } else if (normalizedArgs && paramName in normalizedArgs) {
+ functionArgs.push(normalizedArgs[paramName]);
+ console.log(
+ `[DirectExecutor] Added ${paramName} from args:`,
+ normalizedArgs[paramName]
+ );
+ } else if (
+ normalizedArgs &&
+ Object.keys(normalizedArgs).length === 1 &&
+ !paramNames.some((p: string) => p in normalizedArgs)
+ ) {
+ // If single arg that doesn't match param names, use it as positional
+ const value = Object.values(normalizedArgs)[0];
+ functionArgs.push(value);
+ console.log("[DirectExecutor] Added single positional arg:", value);
+ } else {
+ // Skip optional parameters
+ console.log(
+ `[DirectExecutor] Skipping optional parameter: ${paramName}`
+ );
+ continue;
+ }
+ }
+
+ console.log(
+ "[DirectExecutor] Calling function with args:",
+ functionArgs.length,
+ "arguments"
+ );
+ // Don't log the client object as it causes circular reference
+ const loggableArgs = functionArgs.map((arg, i) => {
+ if (paramNames[i] === "client") return "[SupabaseClient]";
+ return arg;
+ });
+ console.log(
+ "[DirectExecutor] Actual args being passed:",
+ JSON.stringify(loggableArgs, null, 2)
+ );
+
+ // Execute the function
+ let result = await (func as Function)(...functionArgs);
+
+ console.log("[DirectExecutor] Function executed successfully");
+ console.log("[DirectExecutor] Raw result type:", typeof result);
+
+ // Check if result is a Supabase query builder (it's thenable but not yet executed)
+ // Supabase queries are thenable objects that need to be awaited
+ if (
+ result &&
+ typeof result === "object" &&
+ typeof result.then === "function"
+ ) {
+ console.log(
+ "[DirectExecutor] Result is thenable (likely Supabase query), awaiting execution..."
+ );
+ try {
+ const executedResult = await result;
+ console.log("[DirectExecutor] Query executed successfully");
+ console.log(
+ "[DirectExecutor] Executed result type:",
+ typeof executedResult
+ );
+ if (executedResult && typeof executedResult === "object") {
+ console.log(
+ "[DirectExecutor] Result has keys:",
+ Object.keys(executedResult)
+ );
+ if ("data" in executedResult) {
+ console.log(
+ "[DirectExecutor] Result has data property, length:",
+ Array.isArray(executedResult.data)
+ ? executedResult.data.length
+ : "not array"
+ );
+ }
+ if ("error" in executedResult) {
+ console.log(
+ "[DirectExecutor] Result has error:",
+ executedResult.error
+ );
+ }
+ if ("count" in executedResult) {
+ console.log("[DirectExecutor] Result count:", executedResult.count);
+ }
+ }
+ result = executedResult;
+ } catch (queryError: any) {
+ console.error("[DirectExecutor] Query execution failed:", queryError);
+ throw queryError;
+ }
+ }
+
+ // Log result safely
+ try {
+ const resultPreview = JSON.stringify(result, null, 2).substring(0, 500);
+ console.log("[DirectExecutor] Final result preview:", resultPreview);
+ } catch (_e) {
+ console.log(
+ "[DirectExecutor] Could not stringify result, likely contains circular references"
+ );
+ console.log(
+ "[DirectExecutor] Result keys:",
+ result && typeof result === "object" ? Object.keys(result) : "N/A"
+ );
+ }
+
+ return {
+ success: true,
+ data: result
+ };
+ } catch (error: any) {
+ console.error("[DirectExecutor] Function execution failed:", error);
+ console.error("[DirectExecutor] Error stack:", error.stack);
+ return {
+ success: false,
+ error: error.message || "Function execution failed"
+ };
+ }
+}
+
+// Helper to search available functions
+export function searchFunctions(query?: string, module?: string): string[] {
+ const results: string[] = [];
+
+ Object.entries(functionRegistry).forEach(([moduleName, functions]) => {
+ if (module && moduleName !== module) return;
+
+ Object.keys(functions).forEach((funcName) => {
+ const fullName = `${moduleName}_${funcName}`;
+ if (isMcpBlockedTool(fullName)) return;
+ if (!query || fullName.toLowerCase().includes(query.toLowerCase())) {
+ results.push(fullName);
+ }
+ });
+ });
+
+ return results;
+}
diff --git a/apps/erp/app/routes/api+/mcp+/lib/mcp-blocked-tools.ts b/apps/erp/app/routes/api+/mcp+/lib/mcp-blocked-tools.ts
new file mode 100644
index 0000000000..747a49df34
--- /dev/null
+++ b/apps/erp/app/routes/api+/mcp+/lib/mcp-blocked-tools.ts
@@ -0,0 +1,11 @@
+/**
+ * Tools excluded from MCP discovery (tool-metadata.json) and blocked at runtime.
+ * Keep this list small; add only operations that must never run via /api/mcp.
+ */
+export const MCP_BLOCKED_TOOL_NAMES: readonly string[] = [
+ "settings_seedCompany"
+];
+
+export function isMcpBlockedTool(name: string): boolean {
+ return MCP_BLOCKED_TOOL_NAMES.includes(name);
+}
diff --git a/apps/erp/app/routes/api+/mcp+/lib/server.ts b/apps/erp/app/routes/api+/mcp+/lib/server.ts
index 9f506f5061..5325648bb3 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/server.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/server.ts
@@ -1,59 +1,57 @@
// @ts-nocheck
-// AUTO-GENERATED by scripts/generate-mcp.ts — do not edit manually
+// MCP server with single search tool that dynamically registers others
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
import type { McpContext } from "./types";
-import {
- registerAccountTools,
- registerAccountingTools,
- registerDocumentsTools,
- registerInventoryTools,
- registerInvoicingTools,
- registerItemsTools,
- registerPeopleTools,
- registerProductionTools,
- registerPurchasingTools,
- registerQualityTools,
- registerResourcesTools,
- registerSalesTools,
- registerSettingsTools,
- registerSharedTools,
- registerUsersTools,
-} from "./tools";
+import { z } from "zod";
+import { withErrorHandling, READ_ONLY_ANNOTATIONS, WRITE_ANNOTATIONS } from "./types";
+import toolMetadata from "./tool-metadata.json";
+import { isMcpBlockedTool } from "./mcp-blocked-tools";
+import { executeFunction } from "./direct-executor";
+
+// Tool modules are no longer imported - using direct execution instead
function getServerInstructions(): string {
const today = new Date().toISOString().split("T")[0];
+
+ return `Carbon ERP Manufacturing System
+==========================================
+Date: ${today}
+
+IMPORTANT: Tool Discovery System
+This server has ${toolMetadata.totalTools} tools available across ${toolMetadata.modules} modules.
+
+To prevent context exhaustion, tools are loaded on-demand using call_tool.
+
+USAGE:
+1. Use search_tools to discover available tool names
+2. Use describe_tool to get the schema for a specific tool
+3. Use call_tool to execute any tool with its parameters
+
+EXAMPLES:
+// Step 1: Discover tools
+search_tools({ query: "customer" })
+// Returns tool names like: sales_getCustomers, sales_getCustomersList
+
+// Step 2 (optional): Get tool schema
+describe_tool({ name: "sales_getCustomers" })
- return `Carbon ERP is a manufacturing system. This MCP server provides access to ERP data including sales, purchasing, inventory, production, quality, and more.
-
-## Current Date
-Today is ${today}.
-
-## Tool Organization
-Tools are namespaced by module — use the prefix to discover related tools:
-- account_* — 6 read, 3 write, 1 delete tools
-- accounting_* — 27 read, 8 write, 4 delete tools
-- documents_* — 4 read, 7 write, 3 delete tools
-- inventory_* — 45 read, 15 write, 12 delete tools
-- invoicing_* — 11 read, 13 write, 4 delete tools
-- items_* — 75 read, 44 write, 17 delete tools
-- people_* — 24 read, 14 write, 6 delete tools
-- production_* — 62 read, 45 write, 22 delete tools
-- purchasing_* — 51 read, 34 write, 11 delete tools
-- quality_* — 38 read, 19 write, 11 delete tools
-- resources_* — 47 read, 27 write, 20 delete tools
-- sales_* — 78 read, 54 write, 18 delete tools
-- settings_* — 26 read, 40 write, 2 delete tools
-- shared_* — 20 read, 20 write, 4 delete tools
-- users_* — 17 read, 6 write, 2 delete tools
-
-## Key Patterns
-- All monetary amounts use the company's base currency unless specified.
-- Date parameters use ISO 8601 format (YYYY-MM-DD).
-- List tools support pagination via limit/offset (GenericQueryFilters).
-- companyId and userId are auto-filled from the authenticated context — do not provide them.
-- Most get/list tools return { data, error, count? } — check error before using data.
-- Tool errors return isError: true with a text explanation.
-`;
+// Step 3: Call the tool (arguments must be a JSON object, not a string)
+call_tool({
+ name: "sales_getCustomers",
+ arguments: { args: { limit: 10 } }
+})
+
+SEARCH EXAMPLES:
+search_tools({ query: "customer" }) // Find customer-related tools
+search_tools({ module: "sales" }) // Find all sales module tools
+search_tools({ classification: "READ" }) // Find read-only tools
+
+KEY PATTERNS:
+- companyId/userId are auto-filled
+- call_tool.arguments is always a JSON object (never a stringified JSON blob)
+- Responses: { data, error?, count? }
+- Dates: ISO 8601 (YYYY-MM-DD)
+- Pagination: limit/offset`;
}
export function createMcpServer(ctx: McpContext): McpServer {
@@ -67,21 +65,239 @@ export function createMcpServer(ctx: McpContext): McpServer {
},
);
- registerAccountTools(server, ctx);
- registerAccountingTools(server, ctx);
- registerDocumentsTools(server, ctx);
- registerInventoryTools(server, ctx);
- registerInvoicingTools(server, ctx);
- registerItemsTools(server, ctx);
- registerPeopleTools(server, ctx);
- registerProductionTools(server, ctx);
- registerPurchasingTools(server, ctx);
- registerQualityTools(server, ctx);
- registerResourcesTools(server, ctx);
- registerSalesTools(server, ctx);
- registerSettingsTools(server, ctx);
- registerSharedTools(server, ctx);
- registerUsersTools(server, ctx);
+
+ // Register describe_tool to get schema information for any tool
+ server.registerTool(
+ "describe_tool",
+ {
+ description: "Get the schema and description for a specific tool",
+ inputSchema: z.object({
+ name: z.string().describe("The name of the tool to describe")
+ }),
+ annotations: READ_ONLY_ANNOTATIONS
+ },
+ withErrorHandling(async (params: any) => {
+ const { name } = params;
+
+ console.log("[MCP Server] describe_tool invoked for:", name);
+
+ // Find the tool in metadata
+ const tool = toolMetadata.tools.find(t => t.name === name);
+ if (!tool) {
+ console.error("[MCP Server] Tool not found:", name);
+ return {
+ content: [{ type: "text" as const, text: `Tool '${name}' not found` }],
+ isError: true
+ };
+ }
+
+ console.log("[MCP Server] Found tool:", tool.name, "in module:", tool.module);
+
+ // Tool schemas are provided via metadata, no need to load modules
+
+ let output = `Tool: ${name}\n`;
+ output += `Module: ${tool.module}\n`;
+ output += `Classification: ${tool.classification}\n`;
+ output += `Description: ${tool.description}\n\n`;
+
+ output += `Input Schema:\n`;
+ output += JSON.stringify(tool.schema || {}, null, 2);
+
+ return {
+ content: [{ type: "text" as const, text: output }]
+ };
+ }, "Describe tool failed")
+ );
+
+ // Register call_tool with direct execution
+ server.registerTool(
+ "call_tool",
+ {
+ description: "Call any ERP tool by name with the specified parameters",
+ inputSchema: z.object({
+ name: z.string().describe("The name of the tool to call"),
+ arguments: z.any().describe("The arguments to pass to the tool")
+ }),
+ annotations: WRITE_ANNOTATIONS
+ },
+ withErrorHandling(async (params: any) => {
+ const { name, arguments: rawArgs } = params;
+ let args = rawArgs;
+
+ // Some MCP clients send arguments as a JSON string; normalize to object.
+ if (typeof args === "string") {
+ try {
+ args = args.trim().length > 0 ? JSON.parse(args) : {};
+ } catch {
+ return {
+ content: [{ type: "text" as const, text: "Invalid JSON in call_tool.arguments" }],
+ isError: true
+ };
+ }
+ }
+
+ console.log("[MCP Server] call_tool invoked:", { name, arguments: args });
+
+ if (isMcpBlockedTool(name)) {
+ return {
+ content: [{
+ type: "text" as const,
+ text: `Tool disabled: ${name} is not available via MCP.`
+ }],
+ isError: true
+ };
+ }
+
+ // Use direct executor instead of MCP protocol
+ const result = await executeFunction(name, ctx, args);
+
+ console.log("[MCP Server] Execution result:", {
+ success: result.success,
+ hasData: !!result.data,
+ error: result.error
+ });
+
+ if (result.success) {
+ // Format successful response
+ let output = "";
+
+ // Check if the result.data is a Supabase response format
+ if (result.data && typeof result.data === 'object' && 'data' in result.data) {
+ // Supabase format: { data: [...], error: null, count: ... }
+ const supabaseData = result.data.data;
+ console.log("[MCP Server] Detected Supabase response format");
+ console.log("[MCP Server] Data array length:", Array.isArray(supabaseData) ? supabaseData.length : 'not array');
+
+ if (result.data.error) {
+ console.error("[MCP Server] Supabase error:", result.data.error);
+ return {
+ content: [{ type: "text" as const, text: `Database error: ${JSON.stringify(result.data.error)}` }],
+ isError: true
+ };
+ }
+
+ output = JSON.stringify(supabaseData, null, 2);
+ } else if (result.data) {
+ output = JSON.stringify(result.data, null, 2);
+ console.log("[MCP Server] Using result.data for output");
+ } else {
+ output = "Operation completed successfully";
+ console.log("[MCP Server] No data in result, using default message");
+ }
+
+ console.log("[MCP Server] Returning output (truncated):", output.substring(0, 200));
+
+ return {
+ content: [{ type: "text" as const, text: output }]
+ };
+ } else {
+ console.error("[MCP Server] Tool execution failed:", result.error);
+ return {
+ content: [{ type: "text" as const, text: `Error: ${result.error}` }],
+ isError: true
+ };
+ }
+ }, "Call tool failed")
+ );
+
+ // Register search_tools for discovery
+ server.registerTool(
+ "search_tools",
+ {
+ description: "Search for ERP tools and automatically make them available for use",
+ inputSchema: z.object({
+ query: z.string().optional().describe("Search in tool names/descriptions"),
+ module: z.string().optional().describe("Filter by module name"),
+ classification: z.enum(["READ", "WRITE", "DESTRUCTIVE"]).optional(),
+ limit: z.number().int().min(1).max(100).default(20),
+ offset: z.number().int().min(0).default(0)
+ }),
+ annotations: READ_ONLY_ANNOTATIONS
+ },
+ withErrorHandling(async (params: any) => {
+ const { query, module, classification, limit = 20, offset = 0 } = params;
+
+ console.log("[MCP Server] search_tools invoked:", { query, module, classification, limit, offset });
+
+ let results = toolMetadata.tools;
+ console.log("[MCP Server] Total tools available:", results.length);
+
+ // Apply filters
+ if (module) {
+ results = results.filter(t => t.module.toLowerCase().includes(module.toLowerCase()));
+ }
+ if (classification) {
+ results = results.filter(t => t.classification === classification);
+ }
+ if (query) {
+ const q = query.toLowerCase();
+ results = results.filter(t =>
+ t.name.toLowerCase().includes(q) ||
+ t.description.toLowerCase().includes(q) ||
+ t.module.toLowerCase().includes(q)
+ );
+ }
+
+ const foundTools = results.slice(offset, offset + limit);
+ const toolNames = foundTools.map(t => t.name);
+
+ console.log("[MCP Server] Found tools after filtering:", results.length);
+ console.log("[MCP Server] Returning tools:", toolNames);
+
+ // Build response
+ let output = `Found ${results.length} tools`;
+ if (results.length > limit) {
+ output += ` (showing ${offset + 1}-${offset + foundTools.length})`;
+ }
+ output += ":\n\n";
+
+ // Group by module
+ const byModule = new Map<string, typeof foundTools>();
+ for (const tool of foundTools) {
+ if (!byModule.has(tool.module)) {
+ byModule.set(tool.module, []);
+ }
+ byModule.get(tool.module)!.push(tool);
+ }
+
+ // Format results
+ for (const [mod, tools] of byModule.entries()) {
+ output += `${mod.toUpperCase()} MODULE:\n`;
+
+ for (const tool of tools) {
+ output += ` • ${tool.name} [${tool.classification}]\n`;
+ output += ` ${tool.description}\n`;
+ }
+ output += "\n";
+ }
+
+ // Add instructions for using call_tool
+ if (toolNames.length > 0) {
+ output += `\n━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n`;
+ output += `To use these tools:\n`;
+ output += `1. Use describe_tool({ name: "tool_name" }) to see the schema\n`;
+ output += `2. Use call_tool({ name: "tool_name", arguments: {...} })\n\n`;
+ output += `Example:\n`;
+ output += `call_tool({ \n`;
+ output += ` name: "${toolNames[0]}",\n`;
+ output += ` arguments: { /* tool parameters */ }\n`;
+ output += `})\n`;
+ output += `\nAvailable tools:\n`;
+ output += toolNames.map(name => ` • ${name}`).join('\n');
+ output += `\n━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n`;
+ }
+
+ output += `\nSTATUS: ${toolMetadata.totalTools} tools available via call_tool`;
+
+ return {
+ content: [{ type: "text" as const, text: output }],
+ metadata: {
+ toolNames,
+ totalResults: results.length
+ }
+ };
+ }, "Search failed")
+ );
return server;
-}
+}
\ No newline at end of file
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json b/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json
new file mode 100644
index 0000000000..13ab1aed4e
--- /dev/null
+++ b/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json
@@ -0,0 +1,7119 @@
+{
+ "generated": "2026-04-14T16:17:40.073Z",
+ "totalTools": 1016,
+ "modules": 15,
+ "tools": [
+ {
+ "name": "account_deleteUserAttributeValue",
+ "module": "account",
+ "classification": "DESTRUCTIVE",
+ "description": "delete user attribute value",
+ "paramCount": 3
+ },
+ {
+ "name": "account_getAccount",
+ "module": "account",
+ "classification": "READ",
+ "description": "get account",
+ "paramCount": 1
+ },
+ {
+ "name": "account_getAttributes",
+ "module": "account",
+ "classification": "READ",
+ "description": "get attributes",
+ "paramCount": 1
+ },
+ {
+ "name": "account_getPrivateAttributes",
+ "module": "account",
+ "classification": "READ",
+ "description": "get private attributes",
+ "paramCount": 0
+ },
+ {
+ "name": "account_getPublicAttributes",
+ "module": "account",
+ "classification": "READ",
+ "description": "get public attributes",
+ "paramCount": 0
+ },
+ {
+ "name": "account_getAllAttributeCategories",
+ "module": "account",
+ "classification": "READ",
+ "description": "get all attribute categories",
+ "paramCount": 0
+ },
+ {
+ "name": "account_getAttributeCategoryWithValues",
+ "module": "account",
+ "classification": "READ",
+ "description": "get attribute category with values",
+ "paramCount": 1
+ },
+ {
+ "name": "account_updateAvatar",
+ "module": "account",
+ "classification": "WRITE",
+ "description": "update avatar",
+ "paramCount": 1
+ },
+ {
+ "name": "account_updatePublicAccount",
+ "module": "account",
+ "classification": "WRITE",
+ "description": "update public account",
+ "paramCount": 5
+ },
+ {
+ "name": "account_upsertUserAttributeValue",
+ "module": "account",
+ "classification": "WRITE",
+ "description": "upsert user attribute value",
+ "paramCount": 5
+ },
+ {
+ "name": "accounting_deleteAccount",
+ "module": "accounting",
+ "classification": "DESTRUCTIVE",
+ "description": "delete account",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_deleteAccountCategory",
+ "module": "accounting",
+ "classification": "DESTRUCTIVE",
+ "description": "delete account category",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_deleteAccountSubcategory",
+ "module": "accounting",
+ "classification": "DESTRUCTIVE",
+ "description": "delete account subcategory",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_deletePaymentTerm",
+ "module": "accounting",
+ "classification": "DESTRUCTIVE",
+ "description": "delete payment term",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getAccount",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getAccounts",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get accounts",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getAccountsList",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get accounts list",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getAccountCategories",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account categories",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getAccountCategoriesList",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account categories list",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getAccountCategory",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account category",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getAccountSubcategories",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account subcategories",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getAccountSubcategoriesByCategory",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account subcategories by category",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getAccountSubcategory",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get account subcategory",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getBaseCurrency",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get base currency",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getChartOfAccounts",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get chart of accounts",
+ "paramCount": 7
+ },
+ {
+ "name": "accounting_getCurrency",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get currency",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getCurrencyByCode",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get currency by code",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getCurrencies",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get currencies",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getCurrenciesList",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get currencies list",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getCurrentAccountingPeriod",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get current accounting period",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getDefaultAccounts",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get default accounts",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getFiscalYearSettings",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get fiscal year settings",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getInventoryPostingGroup",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get inventory posting group",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_getInventoryPostingGroups",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get inventory posting groups",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_getPaymentTerm",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get payment term",
+ "paramCount": 1
+ },
+ {
+ "name": "accounting_getPaymentTerms",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get payment terms",
+ "paramCount": 4
+ },
+ {
+ "name": "accounting_getPaymentTermsList",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get payment terms list",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_getPurchasingPostingGroup",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get purchasing posting group",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_getPurchasingPostingGroups",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get purchasing posting groups",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_getPurchasingSalesGroup",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get purchasing sales group",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_getSalesPostingGroups",
+ "module": "accounting",
+ "classification": "READ",
+ "description": "get sales posting groups",
+ "paramCount": 3
+ },
+ {
+ "name": "accounting_updateDefaultBalanceSheetAccounts",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "update default balance sheet accounts",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_updateDefaultIncomeAccounts",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "update default income accounts",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_updateFiscalYearSettings",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "update fiscal year settings",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_upsertAccount",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "upsert account",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_upsertAccountCategory",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "upsert account category",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_upsertAccountSubcategory",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "upsert account subcategory",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_upsertCurrency",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "upsert currency",
+ "paramCount": 0
+ },
+ {
+ "name": "accounting_upsertPaymentTerm",
+ "module": "accounting",
+ "classification": "WRITE",
+ "description": "upsert payment term",
+ "paramCount": 0
+ },
+ {
+ "name": "documents_deleteDocument",
+ "module": "documents",
+ "classification": "DESTRUCTIVE",
+ "description": "delete document",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_deleteDocumentFavorite",
+ "module": "documents",
+ "classification": "DESTRUCTIVE",
+ "description": "delete document favorite",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_deleteDocumentLabel",
+ "module": "documents",
+ "classification": "DESTRUCTIVE",
+ "description": "delete document label",
+ "paramCount": 2
+ },
+ {
+ "name": "documents_getDocument",
+ "module": "documents",
+ "classification": "READ",
+ "description": "get document",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_getDocuments",
+ "module": "documents",
+ "classification": "READ",
+ "description": "get documents",
+ "paramCount": 7
+ },
+ {
+ "name": "documents_getDocumentExtensions",
+ "module": "documents",
+ "classification": "READ",
+ "description": "get document extensions",
+ "paramCount": 0
+ },
+ {
+ "name": "documents_getDocumentLabels",
+ "module": "documents",
+ "classification": "READ",
+ "description": "get document labels",
+ "paramCount": 0
+ },
+ {
+ "name": "documents_insertDocumentFavorite",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "insert document favorite",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_insertDocumentLabel",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "insert document label",
+ "paramCount": 2
+ },
+ {
+ "name": "documents_moveDocumentToTrash",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "move document to trash",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_restoreDocument",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "restore document",
+ "paramCount": 1
+ },
+ {
+ "name": "documents_upsertDocument",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "upsert document",
+ "paramCount": 0
+ },
+ {
+ "name": "documents_updateDocumentFavorite",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "update document favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "documents_updateDocumentLabels",
+ "module": "documents",
+ "classification": "WRITE",
+ "description": "update document labels",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_deleteBatchProperty",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete batch property",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteKanban",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete kanban",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteReceipt",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete receipt",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteReceiptLine",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete receipt line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteShelf",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shelf",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteShipment",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteShipmentLine",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shipment line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteShippingMethod",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shipping method",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteStockTransfer",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete stock transfer",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteStockTransferLine",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete stock transfer line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteWarehouseTransfer",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete warehouse transfer",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_deleteWarehouseTransferLine",
+ "module": "inventory",
+ "classification": "DESTRUCTIVE",
+ "description": "delete warehouse transfer line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getItemLedgerPage",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get item ledger page",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getBatchProperties",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get batch properties",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getInventoryItems",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get inventory items",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_getInventoryItemsCount",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get inventory items count",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_getKanbans",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get kanbans",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_getKanban",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get kanban",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getStockTransfer",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get stock transfer",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getStockTransferLine",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get stock transfer line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getStockTransferLines",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get stock transfer lines",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getStockTransferTracking",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get stock transfer tracking",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getStockTransfers",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get stock transfers",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_getDefaultShelfOrShelfWithHighestQuantity",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get default shelf or shelf with highest quantity",
+ "paramCount": 2
+ },
+ {
+ "name": "inventory_getReceipts",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipts",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getReceipt",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipt",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getReceiptLines",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipt lines",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getReceiptTracking",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipt tracking",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getReceiptLineTracking",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipt line tracking",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getReceiptFiles",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get receipt files",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getSerialNumbersForItem",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get serial numbers for item",
+ "paramCount": 2
+ },
+ {
+ "name": "inventory_getBatchNumbersForItem",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get batch numbers for item",
+ "paramCount": 3
+ },
+ {
+ "name": "inventory_getShelvesList",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shelves list",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_getShelvesListForLocation",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shelves list for location",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShelves",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shelves",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_getShelf",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shelf",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipments",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipments",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getShipment",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipmentLines",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment lines",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipmentLinesWithDetails",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment lines with details",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipmentFiles",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment files",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipmentRelatedItems",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment related items",
+ "paramCount": 2
+ },
+ {
+ "name": "inventory_getShipmentTracking",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment tracking",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShipmentLineTracking",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipment line tracking",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShippingMethod",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipping method",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getShippingMethods",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipping methods",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getShippingMethodsList",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipping methods list",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_getShippingTermsList",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get shipping terms list",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_getTrackedEntities",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get tracked entities",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getTrackedEntitiesByMakeMethodId",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get tracked entities by make method id",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getTrackedEntity",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get tracked entity",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getTrackedEntitiesByOperationId",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get tracked entities by operation id",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getWarehouseTransfers",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get warehouse transfers",
+ "paramCount": 4
+ },
+ {
+ "name": "inventory_getWarehouseTransfer",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get warehouse transfer",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getWarehouseTransferLine",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get warehouse transfer line",
+ "paramCount": 2
+ },
+ {
+ "name": "inventory_getWarehouseTransferLines",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get warehouse transfer lines",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_insertManualInventoryAdjustment",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "insert manual inventory adjustment",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_updateBatchPropertyOrder",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "update batch property order",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_updateStockTransferStatus",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "update stock transfer status",
+ "paramCount": 5
+ },
+ {
+ "name": "inventory_upsertBatchProperty",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert batch property",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertKanban",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert kanban",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertReceipt",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert receipt",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertShelf",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert shelf",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertShippingMethod",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert shipping method",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertShipment",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert shipment",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertStockTransfer",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert stock transfer",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_upsertStockTransferLine",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert stock transfer line",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertStockTransferLines",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert stock transfer lines",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_upsertWarehouseTransfer",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert warehouse transfer",
+ "paramCount": 0
+ },
+ {
+ "name": "inventory_updateWarehouseTransferStatus",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "update warehouse transfer status",
+ "paramCount": 2
+ },
+ {
+ "name": "inventory_upsertWarehouseTransferLine",
+ "module": "inventory",
+ "classification": "WRITE",
+ "description": "upsert warehouse transfer line",
+ "paramCount": 1
+ },
+ {
+ "name": "inventory_getDefaultShelfForJob",
+ "module": "inventory",
+ "classification": "READ",
+ "description": "get default shelf for job",
+ "paramCount": 2
+ },
+ {
+ "name": "invoicing_createPurchaseInvoiceFromPurchaseOrder",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "create purchase invoice from purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_createSalesInvoiceFromSalesOrder",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "create sales invoice from sales order",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_createSalesInvoiceFromShipment",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "create sales invoice from shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_deletePurchaseInvoice",
+ "module": "invoicing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchase invoice",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_deletePurchaseInvoiceLine",
+ "module": "invoicing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchase invoice line",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_deleteSalesInvoice",
+ "module": "invoicing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales invoice",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_deleteSalesInvoiceLine",
+ "module": "invoicing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales invoice line",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getPurchaseInvoice",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get purchase invoice",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getPurchaseInvoices",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get purchase invoices",
+ "paramCount": 5
+ },
+ {
+ "name": "invoicing_getPurchaseInvoiceDelivery",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get purchase invoice delivery",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getPurchaseInvoiceLines",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get purchase invoice lines",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getPurchaseInvoiceLine",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get purchase invoice line",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getSalesInvoice",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoice",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getSalesInvoiceCustomerDetails",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoice customer details",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getSalesInvoices",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoices",
+ "paramCount": 5
+ },
+ {
+ "name": "invoicing_getSalesInvoiceShipment",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoice shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getSalesInvoiceLines",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoice lines",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_getSalesInvoiceLine",
+ "module": "invoicing",
+ "classification": "READ",
+ "description": "get sales invoice line",
+ "paramCount": 1
+ },
+ {
+ "name": "invoicing_updatePurchaseInvoiceExchangeRate",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "update purchase invoice exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "invoicing_updatePurchaseInvoiceStatus",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "update purchase invoice status",
+ "paramCount": 4
+ },
+ {
+ "name": "invoicing_updateSalesInvoiceExchangeRate",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "update sales invoice exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "invoicing_updateSalesInvoiceStatus",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "update sales invoice status",
+ "paramCount": 4
+ },
+ {
+ "name": "invoicing_upsertPurchaseInvoice",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert purchase invoice",
+ "paramCount": 0
+ },
+ {
+ "name": "invoicing_upsertPurchaseInvoiceDelivery",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert purchase invoice delivery",
+ "paramCount": 0
+ },
+ {
+ "name": "invoicing_upsertPurchaseInvoiceLine",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert purchase invoice line",
+ "paramCount": 0
+ },
+ {
+ "name": "invoicing_upsertSalesInvoice",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert sales invoice",
+ "paramCount": 0
+ },
+ {
+ "name": "invoicing_upsertSalesInvoiceShipment",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert sales invoice shipment",
+ "paramCount": 0
+ },
+ {
+ "name": "invoicing_upsertSalesInvoiceLine",
+ "module": "invoicing",
+ "classification": "WRITE",
+ "description": "upsert sales invoice line",
+ "paramCount": 0
+ },
+ {
+ "name": "items_activateMethodVersion",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "activate method version",
+ "paramCount": 2
+ },
+ {
+ "name": "items_copyItem",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "copy item",
+ "paramCount": 0
+ },
+ {
+ "name": "items_copyMakeMethod",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "copy make method",
+ "paramCount": 0
+ },
+ {
+ "name": "items_createRevision",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "create revision",
+ "paramCount": 3
+ },
+ {
+ "name": "items_deleteConfigurationParameter",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete configuration parameter",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteConfigurationRule",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete configuration rule",
+ "paramCount": 2
+ },
+ {
+ "name": "items_deleteItemCustomerPart",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete item customer part",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteConfigurationParameterGroup",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete configuration parameter group",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteItem",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete item",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteItemPostingGroup",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete item posting group",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMaterialDimension",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material dimension",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMaterialFinish",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material finish",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMaterialForm",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material form",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMaterialGrade",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material grade",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMaterialSubstance",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material substance",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMethodMaterial",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete method material",
+ "paramCount": 1
+ },
+ {
+ "name": "items_assertMethodOperationIsDraft",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "assert method operation is draft",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMethodOperationStep",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete method operation step",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMethodOperationParameter",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete method operation parameter",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteMethodOperationTool",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete method operation tool",
+ "paramCount": 1
+ },
+ {
+ "name": "items_deleteUnitOfMeasure",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete unit of measure",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getConfigurationParameters",
+ "module": "items",
+ "classification": "READ",
+ "description": "get configuration parameters",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getConfigurationRules",
+ "module": "items",
+ "classification": "READ",
+ "description": "get configuration rules",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getConsumable",
+ "module": "items",
+ "classification": "READ",
+ "description": "get consumable",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getConsumables",
+ "module": "items",
+ "classification": "READ",
+ "description": "get consumables",
+ "paramCount": 5
+ },
+ {
+ "name": "items_getConsumablesList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get consumables list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getItem",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemCost",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item cost",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemCostHistory",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item cost history",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemCustomerPart",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item customer part",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemCustomerParts",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item customer parts",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemDemand",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item demand",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getItemFiles",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item files",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemPostingGroup",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item posting group",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemPostingGroups",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item posting groups",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getItemPostingGroupsList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item posting groups list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getItemManufacturing",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item manufacturing",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemPlanning",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item planning",
+ "paramCount": 2
+ },
+ {
+ "name": "items_getItemQuantities",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item quantities",
+ "paramCount": 2
+ },
+ {
+ "name": "items_getItemReplenishment",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item replenishment",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getItemShelfQuantities",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item shelf quantities",
+ "paramCount": 2
+ },
+ {
+ "name": "items_getItemSupply",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item supply",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getItemUnitSalePrice",
+ "module": "items",
+ "classification": "READ",
+ "description": "get item unit sale price",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialUsedIn",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material used in",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMakeMethods",
+ "module": "items",
+ "classification": "READ",
+ "description": "get make methods",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMakeMethodById",
+ "module": "items",
+ "classification": "READ",
+ "description": "get make method by id",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterial",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterials",
+ "module": "items",
+ "classification": "READ",
+ "description": "get materials",
+ "paramCount": 5
+ },
+ {
+ "name": "items_getMaterialsList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get materials list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getMaterialDimension",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material dimension",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialDimensions",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material dimensions",
+ "paramCount": 5
+ },
+ {
+ "name": "items_getMaterialDimensionList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material dimension list",
+ "paramCount": 2
+ },
+ {
+ "name": "items_getMaterialFinish",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material finish",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialFinishes",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material finishes",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMaterialFinishList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material finish list",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialForm",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material form",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialForms",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material forms",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMaterialFormsList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material forms list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getMaterialGrades",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material grades",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMaterialGrade",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material grade",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialGradeList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material grade list",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialSubstance",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material substance",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialSubstances",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material substances",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMaterialSubstancesList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material substances list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getMethodMaterial",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method material",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMethodMaterials",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method materials",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMethodMaterialsByMakeMethod",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method materials by make method",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMethodOperations",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method operations",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMethodOperationsByMakeMethodId",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method operations by make method id",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMethodTree",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method tree",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMethodTreeArray",
+ "module": "items",
+ "classification": "READ",
+ "description": "get method tree array",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getOpenJobMaterials",
+ "module": "items",
+ "classification": "READ",
+ "description": "get open job materials",
+ "paramCount": 3
+ },
+ {
+ "name": "items_getOpenProductionOrders",
+ "module": "items",
+ "classification": "READ",
+ "description": "get open production orders",
+ "paramCount": 3
+ },
+ {
+ "name": "items_getOpenPurchaseOrderLines",
+ "module": "items",
+ "classification": "READ",
+ "description": "get open purchase order lines",
+ "paramCount": 3
+ },
+ {
+ "name": "items_getOpenSalesOrderLines",
+ "module": "items",
+ "classification": "READ",
+ "description": "get open sales order lines",
+ "paramCount": 3
+ },
+ {
+ "name": "items_getPart",
+ "module": "items",
+ "classification": "READ",
+ "description": "get part",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getParts",
+ "module": "items",
+ "classification": "READ",
+ "description": "get parts",
+ "paramCount": 5
+ },
+ {
+ "name": "items_getPartsList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get parts list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getPartUsedIn",
+ "module": "items",
+ "classification": "READ",
+ "description": "get part used in",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getPickMethod",
+ "module": "items",
+ "classification": "READ",
+ "description": "get pick method",
+ "paramCount": 2
+ },
+ {
+ "name": "items_getPickMethods",
+ "module": "items",
+ "classification": "READ",
+ "description": "get pick methods",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getServices",
+ "module": "items",
+ "classification": "READ",
+ "description": "get services",
+ "paramCount": 7
+ },
+ {
+ "name": "items_getService",
+ "module": "items",
+ "classification": "READ",
+ "description": "get service",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getServicesList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get services list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getSupplierParts",
+ "module": "items",
+ "classification": "READ",
+ "description": "get supplier parts",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getTool",
+ "module": "items",
+ "classification": "READ",
+ "description": "get tool",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getTools",
+ "module": "items",
+ "classification": "READ",
+ "description": "get tools",
+ "paramCount": 5
+ },
+ {
+ "name": "items_getToolsList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get tools list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getUnitOfMeasure",
+ "module": "items",
+ "classification": "READ",
+ "description": "get unit of measure",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getUnitOfMeasures",
+ "module": "items",
+ "classification": "READ",
+ "description": "get unit of measures",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getUnitOfMeasuresList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get unit of measures list",
+ "paramCount": 0
+ },
+ {
+ "name": "items_updateConfigurationParameterGroupOrder",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update configuration parameter group order",
+ "paramCount": 0
+ },
+ {
+ "name": "items_updateDefaultRevision",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update default revision",
+ "paramCount": 2
+ },
+ {
+ "name": "items_updateConfigurationParameterOrder",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update configuration parameter order",
+ "paramCount": 0
+ },
+ {
+ "name": "items_updateItemCost",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update item cost",
+ "paramCount": 3
+ },
+ {
+ "name": "items_updateMaterialOrder",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update material order",
+ "paramCount": 3
+ },
+ {
+ "name": "items_updateOperationOrder",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update operation order",
+ "paramCount": 3
+ },
+ {
+ "name": "items_updateRevision",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update revision",
+ "paramCount": 3
+ },
+ {
+ "name": "items_upsertConfigurationParameter",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert configuration parameter",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertConfigurationParameterGroup",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert configuration parameter group",
+ "paramCount": 1
+ },
+ {
+ "name": "items_upsertConfigurationRule",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert configuration rule",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertConsumable",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert consumable",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertPart",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert part",
+ "paramCount": 0
+ },
+ {
+ "name": "items_updateItem",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "update item",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemCost",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item cost",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertPickMethod",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert pick method",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemManufacturing",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item manufacturing",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemPlanning",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item planning",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemPurchasing",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item purchasing",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemPostingGroup",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item posting group",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertSupplierPart",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert supplier part",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemCustomerPart",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item customer part",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertItemUnitSalePrice",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert item unit sale price",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMakeMethodVersion",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert make method version",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMethodMaterial",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert method material",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMethodOperation",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert method operation",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMethodOperationStep",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert method operation step",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMethodOperationParameter",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert method operation parameter",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMethodOperationTool",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert method operation tool",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterial",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterialDimension",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material dimension",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterialFinish",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material finish",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterialForm",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material form",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterialGrade",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material grade",
+ "paramCount": 0
+ },
+ {
+ "name": "items_deleteMaterialType",
+ "module": "items",
+ "classification": "DESTRUCTIVE",
+ "description": "delete material type",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialTypes",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material types",
+ "paramCount": 4
+ },
+ {
+ "name": "items_getMaterialType",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material type",
+ "paramCount": 1
+ },
+ {
+ "name": "items_getMaterialTypeList",
+ "module": "items",
+ "classification": "READ",
+ "description": "get material type list",
+ "paramCount": 2
+ },
+ {
+ "name": "items_upsertMaterialType",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material type",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertMaterialSubstance",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert material substance",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertService",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert service",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertUnitOfMeasure",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert unit of measure",
+ "paramCount": 0
+ },
+ {
+ "name": "items_upsertTool",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "upsert tool",
+ "paramCount": 0
+ },
+ {
+ "name": "items_getSupplierPriceBreaksForItems",
+ "module": "items",
+ "classification": "READ",
+ "description": "get supplier price breaks for items",
+ "paramCount": 1
+ },
+ {
+ "name": "items_lookupBuyPrice",
+ "module": "items",
+ "classification": "WRITE",
+ "description": "lookup buy price",
+ "paramCount": 3
+ },
+ {
+ "name": "items_getSupplierPartPriceBreaks",
+ "module": "items",
+ "classification": "READ",
+ "description": "get supplier part price breaks",
+ "paramCount": 1
+ },
+ {
+ "name": "people_deleteAttribute",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete attribute",
+ "paramCount": 1
+ },
+ {
+ "name": "people_deleteAttributeCategory",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete attribute category",
+ "paramCount": 1
+ },
+ {
+ "name": "people_deleteDepartment",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete department",
+ "paramCount": 1
+ },
+ {
+ "name": "people_deleteHoliday",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete holiday",
+ "paramCount": 1
+ },
+ {
+ "name": "people_deleteShift",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shift",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getAttribute",
+ "module": "people",
+ "classification": "READ",
+ "description": "get attribute",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getAttributeCategories",
+ "module": "people",
+ "classification": "READ",
+ "description": "get attribute categories",
+ "paramCount": 3
+ },
+ {
+ "name": "people_getAttributeCategory",
+ "module": "people",
+ "classification": "READ",
+ "description": "get attribute category",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getAttributeDataTypes",
+ "module": "people",
+ "classification": "READ",
+ "description": "get attribute data types",
+ "paramCount": 0
+ },
+ {
+ "name": "people_getDepartment",
+ "module": "people",
+ "classification": "READ",
+ "description": "get department",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getDepartments",
+ "module": "people",
+ "classification": "READ",
+ "description": "get departments",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getDepartmentsList",
+ "module": "people",
+ "classification": "READ",
+ "description": "get departments list",
+ "paramCount": 0
+ },
+ {
+ "name": "people_getEmployeeJob",
+ "module": "people",
+ "classification": "READ",
+ "description": "get employee job",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getEmployeeSummary",
+ "module": "people",
+ "classification": "READ",
+ "description": "get employee summary",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getHoliday",
+ "module": "people",
+ "classification": "READ",
+ "description": "get holiday",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getHolidays",
+ "module": "people",
+ "classification": "READ",
+ "description": "get holidays",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getPeople",
+ "module": "people",
+ "classification": "READ",
+ "description": "get people",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getContacts",
+ "module": "people",
+ "classification": "READ",
+ "description": "get contacts",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getShift",
+ "module": "people",
+ "classification": "READ",
+ "description": "get shift",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getShifts",
+ "module": "people",
+ "classification": "READ",
+ "description": "get shifts",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getShiftsList",
+ "module": "people",
+ "classification": "READ",
+ "description": "get shifts list",
+ "paramCount": 1
+ },
+ {
+ "name": "people_insertAttribute",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "insert attribute",
+ "paramCount": 6
+ },
+ {
+ "name": "people_insertAttributeCategory",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "insert attribute category",
+ "paramCount": 4
+ },
+ {
+ "name": "people_insertEmployeeJob",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "insert employee job",
+ "paramCount": 3
+ },
+ {
+ "name": "people_updateAttribute",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "update attribute",
+ "paramCount": 5
+ },
+ {
+ "name": "people_updateAttributeCategory",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "update attribute category",
+ "paramCount": 5
+ },
+ {
+ "name": "people_updateAttributeSortOrder",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "update attribute sort order",
+ "paramCount": 3
+ },
+ {
+ "name": "people_updateEmployeeJob",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "update employee job",
+ "paramCount": 1
+ },
+ {
+ "name": "people_upsertDepartment",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "upsert department",
+ "paramCount": 0
+ },
+ {
+ "name": "people_upsertHoliday",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "upsert holiday",
+ "paramCount": 0
+ },
+ {
+ "name": "people_upsertShift",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "upsert shift",
+ "paramCount": 0
+ },
+ {
+ "name": "people_clockIn",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "clock in",
+ "paramCount": 2
+ },
+ {
+ "name": "people_clockOut",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "clock out",
+ "paramCount": 4
+ },
+ {
+ "name": "people_createTimeCardEntry",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "create time card entry",
+ "paramCount": 5
+ },
+ {
+ "name": "people_deleteTimeCardEntry",
+ "module": "people",
+ "classification": "DESTRUCTIVE",
+ "description": "delete time card entry",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getClockedInEmployees",
+ "module": "people",
+ "classification": "READ",
+ "description": "get clocked in employees",
+ "paramCount": 0
+ },
+ {
+ "name": "people_getOpenClockEntry",
+ "module": "people",
+ "classification": "READ",
+ "description": "get open clock entry",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getRecentTimecards",
+ "module": "people",
+ "classification": "READ",
+ "description": "get recent timecards",
+ "paramCount": 0
+ },
+ {
+ "name": "people_getScheduledEmployeesToday",
+ "module": "people",
+ "classification": "READ",
+ "description": "get scheduled employees today",
+ "paramCount": 0
+ },
+ {
+ "name": "people_getTimeCardEntry",
+ "module": "people",
+ "classification": "READ",
+ "description": "get time card entry",
+ "paramCount": 1
+ },
+ {
+ "name": "people_getTimeCardEntries",
+ "module": "people",
+ "classification": "READ",
+ "description": "get time card entries",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getTimecardEntries",
+ "module": "people",
+ "classification": "READ",
+ "description": "get timecard entries",
+ "paramCount": 4
+ },
+ {
+ "name": "people_getWeeklyHoursForEmployees",
+ "module": "people",
+ "classification": "READ",
+ "description": "get weekly hours for employees",
+ "paramCount": 1
+ },
+ {
+ "name": "people_updateTimeCardEntry",
+ "module": "people",
+ "classification": "WRITE",
+ "description": "update time card entry",
+ "paramCount": 5
+ },
+ {
+ "name": "production_convertSalesOrderLinesToJobs",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "convert sales order lines to jobs",
+ "paramCount": 2
+ },
+ {
+ "name": "production_calculateJobPriority",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "calculate job priority",
+ "paramCount": 5
+ },
+ {
+ "name": "production_deleteDemandForecasts",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete demand forecasts",
+ "paramCount": 4
+ },
+ {
+ "name": "production_deleteDemandProjections",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete demand projections",
+ "paramCount": 4
+ },
+ {
+ "name": "production_deleteJob",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteJobMaterial",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job material",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteJobOperation",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job operation",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteJobOperationStep",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job operation step",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteJobOperationParameter",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job operation parameter",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteJobOperationTool",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete job operation tool",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteProcedure",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete procedure",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteProcedureStep",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete procedure step",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteProcedureParameter",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete procedure parameter",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteProductionEvent",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete production event",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteProductionQuantity",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete production quantity",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getActiveJobOperationByJobId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get active job operation by job id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getActiveJobOperationsByLocation",
+ "module": "production",
+ "classification": "READ",
+ "description": "get active job operations by location",
+ "paramCount": 2
+ },
+ {
+ "name": "production_getJobsByDateRange",
+ "module": "production",
+ "classification": "READ",
+ "description": "get jobs by date range",
+ "paramCount": 3
+ },
+ {
+ "name": "production_getUnscheduledJobs",
+ "module": "production",
+ "classification": "READ",
+ "description": "get unscheduled jobs",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getActiveProductionEvents",
+ "module": "production",
+ "classification": "READ",
+ "description": "get active production events",
+ "paramCount": 0
+ },
+ {
+ "name": "production_deleteScrapReason",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete scrap reason",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteFailureMode",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete failure mode",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceDispatch",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceDispatchComment",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch comment",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceDispatchEvent",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch event",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceDispatchItem",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch item",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceDispatchWorkCenter",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch work center",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceSchedule",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance schedule",
+ "paramCount": 1
+ },
+ {
+ "name": "production_deleteMaintenanceScheduleItem",
+ "module": "production",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance schedule item",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getDemandForecasts",
+ "module": "production",
+ "classification": "READ",
+ "description": "get demand forecasts",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getDemandProjections",
+ "module": "production",
+ "classification": "READ",
+ "description": "get demand projections",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getJobDocuments",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job documents",
+ "paramCount": 5
+ },
+ {
+ "name": "production_getJobDocumentsWithItemId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job documents with item id",
+ "paramCount": 2
+ },
+ {
+ "name": "production_getJob",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobByOperationId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job by operation id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobPurchaseOrderLines",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job purchase order lines",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobs",
+ "module": "production",
+ "classification": "READ",
+ "description": "get jobs",
+ "paramCount": 3
+ },
+ {
+ "name": "production_getJobsBySalesOrderLine",
+ "module": "production",
+ "classification": "READ",
+ "description": "get jobs by sales order line",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobsList",
+ "module": "production",
+ "classification": "READ",
+ "description": "get jobs list",
+ "paramCount": 0
+ },
+ {
+ "name": "production_getJobMakeMethodById",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job make method by id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getRootMakeMethod",
+ "module": "production",
+ "classification": "READ",
+ "description": "get root make method",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobMaterialsWithQuantityOnHand",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job materials with quantity on hand",
+ "paramCount": 5
+ },
+ {
+ "name": "production_getJobMethodTree",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job method tree",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobMethodTreeArray",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job method tree array",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobMaterial",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job material",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobMaterialsByMethodId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job materials by method id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperation",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operation",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperations",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operations",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getJobOperationsAssignedToEmployee",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operations assigned to employee",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperationAttachments",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operation attachments",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperationsList",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operations list",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperationsByMethodId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operations by method id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getJobOperationStepRecords",
+ "module": "production",
+ "classification": "READ",
+ "description": "get job operation step records",
+ "paramCount": 5
+ },
+ {
+ "name": "production_getOutsideOperationsByJobId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get outside operations by job id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProcedure",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedure",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProcedureSteps",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedure steps",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProcedureParameters",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedure parameters",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProcedureVersions",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedure versions",
+ "paramCount": 3
+ },
+ {
+ "name": "production_getProcedures",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedures",
+ "paramCount": 3
+ },
+ {
+ "name": "production_getProceduresList",
+ "module": "production",
+ "classification": "READ",
+ "description": "get procedures list",
+ "paramCount": 0
+ },
+ {
+ "name": "production_getProductionEvent",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production event",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProductionEvents",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production events",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getProductionEventsPage",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production events page",
+ "paramCount": 3
+ },
+ {
+ "name": "production_getProductionEventsByOperations",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production events by operations",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProductionPlanning",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production planning",
+ "paramCount": 6
+ },
+ {
+ "name": "production_getProductionProjections",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production projections",
+ "paramCount": 6
+ },
+ {
+ "name": "production_getProductionQuantity",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production quantity",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getProductionQuantities",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production quantities",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getProductionDataByOperations",
+ "module": "production",
+ "classification": "READ",
+ "description": "get production data by operations",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getScrapReasonsList",
+ "module": "production",
+ "classification": "READ",
+ "description": "get scrap reasons list",
+ "paramCount": 0
+ },
+ {
+ "name": "production_getScrapReason",
+ "module": "production",
+ "classification": "READ",
+ "description": "get scrap reason",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getScrapReasons",
+ "module": "production",
+ "classification": "READ",
+ "description": "get scrap reasons",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getFailureMode",
+ "module": "production",
+ "classification": "READ",
+ "description": "get failure mode",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getFailureModes",
+ "module": "production",
+ "classification": "READ",
+ "description": "get failure modes",
+ "paramCount": 4
+ },
+ {
+ "name": "production_getFailureModesList",
+ "module": "production",
+ "classification": "READ",
+ "description": "get failure modes list",
+ "paramCount": 0
+ },
+ {
+ "name": "production_getMaintenanceDispatch",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatch",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceDispatches",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatches",
+ "paramCount": 5
+ },
+ {
+ "name": "production_getMaintenanceDispatchComments",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatch comments",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceDispatchEvents",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatch events",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceDispatchItems",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatch items",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceDispatchWorkCenters",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance dispatch work centers",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceSchedule",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance schedule",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getMaintenanceSchedules",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance schedules",
+ "paramCount": 5
+ },
+ {
+ "name": "production_getMaintenanceScheduleItems",
+ "module": "production",
+ "classification": "READ",
+ "description": "get maintenance schedule items",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getTrackedEntityByJobId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get tracked entity by job id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_getTrackedEntitiesByJobId",
+ "module": "production",
+ "classification": "READ",
+ "description": "get tracked entities by job id",
+ "paramCount": 1
+ },
+ {
+ "name": "production_recalculateJobOperationDependencies",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "recalculate job operation dependencies",
+ "paramCount": 2
+ },
+ {
+ "name": "production_recalculateJobRequirements",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "recalculate job requirements",
+ "paramCount": 2
+ },
+ {
+ "name": "production_recalculateJobMakeMethodRequirements",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "recalculate job make method requirements",
+ "paramCount": 2
+ },
+ {
+ "name": "production_runMRP",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "run m r p",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateJobBatchNumber",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job batch number",
+ "paramCount": 2
+ },
+ {
+ "name": "production_updateJobStatus",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job status",
+ "paramCount": 4
+ },
+ {
+ "name": "production_updateJobMaterialOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job material order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateJobOperationOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job operation order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateJobOperationStepOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job operation step order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateKanbanJob",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update kanban job",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateQuoteOperationStepOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update quote operation step order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateMethodOperationStepOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update method operation step order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_updateJobOperationStatus",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job operation status",
+ "paramCount": 2
+ },
+ {
+ "name": "production_updateJobOperationDueDate",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update job operation due date",
+ "paramCount": 2
+ },
+ {
+ "name": "production_updateProcedureStepOrder",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update procedure step order",
+ "paramCount": 3
+ },
+ {
+ "name": "production_upsertProductionEvent",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert production event",
+ "paramCount": 0
+ },
+ {
+ "name": "production_updateProductionQuantity",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "update production quantity",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertProductionQuantity",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert production quantity",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJob",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job",
+ "paramCount": 1
+ },
+ {
+ "name": "production_upsertJobMaterial",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job material",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJobOperation",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job operation",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJobOperationStep",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job operation step",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJobOperationParameter",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job operation parameter",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJobOperationTool",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job operation tool",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertJobMethod",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job method",
+ "paramCount": 12
+ },
+ {
+ "name": "production_upsertJobMaterialMakeMethod",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert job material make method",
+ "paramCount": 11
+ },
+ {
+ "name": "production_upsertMakeMethodFromJob",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert make method from job",
+ "paramCount": 10
+ },
+ {
+ "name": "production_upsertMakeMethodFromJobMethod",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert make method from job method",
+ "paramCount": 10
+ },
+ {
+ "name": "production_upsertProcedure",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert procedure",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertProcedureStep",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert procedure step",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertProcedureParameter",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert procedure parameter",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertScrapReason",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert scrap reason",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertFailureMode",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert failure mode",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceDispatch",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceDispatchComment",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch comment",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceDispatchEvent",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch event",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceDispatchItem",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch item",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceDispatchWorkCenter",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch work center",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceSchedule",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance schedule",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertMaintenanceScheduleItem",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert maintenance schedule item",
+ "paramCount": 0
+ },
+ {
+ "name": "production_upsertDemandForecasts",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert demand forecasts",
+ "paramCount": 1
+ },
+ {
+ "name": "production_upsertDemandProjections",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "upsert demand projections",
+ "paramCount": 1
+ },
+ {
+ "name": "production_triggerJobSchedule",
+ "module": "production",
+ "classification": "WRITE",
+ "description": "trigger job schedule",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_closePurchaseOrder",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "close purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_convertSupplierQuoteToOrder",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "convert supplier quote to order",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_deletePurchaseOrder",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deletePurchaseOrderLine",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchase order line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deleteSupplier",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deleteSupplierContact",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier contact",
+ "paramCount": 2
+ },
+ {
+ "name": "purchasing_deleteSupplierLocation",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier location",
+ "paramCount": 2
+ },
+ {
+ "name": "purchasing_deleteSupplierProcess",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier process",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deleteSupplierQuote",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier quote",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deleteSupplierQuoteLine",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier quote line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deleteSupplierType",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete supplier type",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrder",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_finalizeSupplierQuote",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "finalize supplier quote",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrders",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase orders",
+ "paramCount": 6
+ },
+ {
+ "name": "purchasing_getPurchaseOrderDelivery",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order delivery",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrderLocations",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order locations",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrderPayment",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order payment",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrderLines",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order lines",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrderLine",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchaseOrderSuppliers",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchase order suppliers",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_getPurchasingDocumentsAssignedToMe",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing documents assigned to me",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_getPurchasingPlanning",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing planning",
+ "paramCount": 6
+ },
+ {
+ "name": "purchasing_getPurchasingTerms",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing terms",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_getSupplier",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierApprovalContext",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier approval context",
+ "paramCount": 2
+ },
+ {
+ "name": "purchasing_getSupplierContact",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier contact",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierContacts",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier contacts",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierInteraction",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier interaction",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierInteractionDocuments",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier interaction documents",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierInteractionLineDocuments",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier interaction line documents",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierLocations",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier locations",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierLocation",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier location",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierPayment",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier payment",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierProcessById",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier process by id",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierProcessesByProcess",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier processes by process",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierProcessesBySupplier",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier processes by supplier",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuote",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuoteByInteractionId",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote by interaction id",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuoteByExternalLinkId",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote by external link id",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuotes",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quotes",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_getSupplierQuoteLine",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuoteLines",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote lines",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuoteLinePrices",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote line prices",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuoteLinePricesByQuoteId",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quote line prices by quote id",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuotesList",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quotes list",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_getSupplierShipping",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier shipping",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSuppliers",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get suppliers",
+ "paramCount": 6
+ },
+ {
+ "name": "purchasing_getSuppliersList",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get suppliers list",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_getSupplierType",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier type",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierTypes",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier types",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_getSupplierTypesList",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier types list",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_insertSupplier",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "insert supplier",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_insertSupplierContact",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "insert supplier contact",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_insertSupplierInteraction",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "insert supplier interaction",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_insertSupplierLocation",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "insert supplier location",
+ "paramCount": 11
+ },
+ {
+ "name": "purchasing_finalizePurchaseOrder",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "finalize purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_sendSupplierQuote",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "send supplier quote",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_updatePurchaseOrder",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update purchase order",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_updatePurchaseOrderExchangeRate",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update purchase order exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_updatePurchaseOrderFavorite",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update purchase order favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_updatePurchaseOrderStatus",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update purchase order status",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_updateSupplierAccounting",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier accounting",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_updateSupplierContact",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier contact",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_updateSupplierLocation",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier location",
+ "paramCount": 11
+ },
+ {
+ "name": "purchasing_updateSupplierPayment",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier payment",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_updateSupplierQuoteExchangeRate",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier quote exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_updateSupplierQuoteFavorite",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier quote favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "purchasing_updateSupplierQuoteStatus",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier quote status",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_updateSupplierShipping",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update supplier shipping",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertPurchaseOrder",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchase order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_upsertPurchaseOrderDelivery",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchase order delivery",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertPurchaseOrderLine",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchase order line",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertPurchaseOrderPayment",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchase order payment",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertSupplier",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert supplier",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertSupplierProcess",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert supplier process",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertSupplierQuote",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert supplier quote",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertSupplierQuoteLine",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert supplier quote line",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_upsertSupplierType",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert supplier type",
+ "paramCount": 0
+ },
+ {
+ "name": "purchasing_deletePurchasingRFQ",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchasing r f q",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_deletePurchasingRFQLine",
+ "module": "purchasing",
+ "classification": "DESTRUCTIVE",
+ "description": "delete purchasing r f q line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchasingRFQ",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f q",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchasingRFQs",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f qs",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_getPurchasingRFQLine",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f q line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchasingRFQLines",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f q lines",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchasingRFQSuppliers",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f q suppliers",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_upsertPurchasingRFQ",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchasing r f q",
+ "paramCount": 9
+ },
+ {
+ "name": "purchasing_upsertPurchasingRFQLine",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchasing r f q line",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_upsertPurchasingRFQSuppliers",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "upsert purchasing r f q suppliers",
+ "paramCount": 2
+ },
+ {
+ "name": "purchasing_updatePurchasingRFQStatus",
+ "module": "purchasing",
+ "classification": "WRITE",
+ "description": "update purchasing r f q status",
+ "paramCount": 4
+ },
+ {
+ "name": "purchasing_getLinkedSupplierQuotes",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get linked supplier quotes",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getLinkedPurchasingRfqs",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get linked purchasing rfqs",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getLinkedPurchasingRfqsForInteraction",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get linked purchasing rfqs for interaction",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSiblingQuotesForQuote",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get sibling quotes for quote",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getLinkedPurchasingRfqsForOrder",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get linked purchasing rfqs for order",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getSupplierQuotesForComparison",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get supplier quotes for comparison",
+ "paramCount": 1
+ },
+ {
+ "name": "purchasing_getPurchasingRFQSuppliersWithLinks",
+ "module": "purchasing",
+ "classification": "READ",
+ "description": "get purchasing r f q suppliers with links",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_activateGauge",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "activate gauge",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deactivateGauge",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "deactivate gauge",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteGauge",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete gauge",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteGaugeCalibrationRecord",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete gauge calibration record",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteGaugeType",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete gauge type",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteIssue",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete issue",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteIssueAssociation",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete issue association",
+ "paramCount": 2
+ },
+ {
+ "name": "quality_deleteIssueType",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete issue type",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteIssueWorkflow",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete issue workflow",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteRequiredAction",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete required action",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteQualityDocument",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quality document",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteQualityDocumentStep",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quality document step",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_deleteRisk",
+ "module": "quality",
+ "classification": "DESTRUCTIVE",
+ "description": "delete risk",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueFromExternalLink",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue from external link",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getGauge",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getGauges",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauges",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getGaugesList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauges list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getGaugeCalibrationRecord",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge calibration record",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getGaugeCalibrationRecords",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge calibration records",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getGaugeCalibrationRecordsByGaugeId",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge calibration records by gauge id",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getGaugeTypesList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge types list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getGaugeType",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge type",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getGaugeTypes",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get gauge types",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getIssue",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssues",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issues",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getIssueWorkflow",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue workflow",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueAction",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue action",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueActionTasks",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue action tasks",
+ "paramCount": 2
+ },
+ {
+ "name": "quality_getIssueApprovalTasks",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue approval tasks",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueItems",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue items",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueAssociations",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue associations",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueReviewers",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue reviewers",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueSuppliers",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue suppliers",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueTasks",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue tasks",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueType",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue type",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getIssueTypes",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue types",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getIssueWorkflows",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue workflows",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getIssueWorkflowsList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue workflows list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getIssueTypesList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get issue types list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getQualityActions",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality actions",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getQualityDocument",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality document",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getQualityDocumentSteps",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality document steps",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getQualityDocumentVersions",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality document versions",
+ "paramCount": 3
+ },
+ {
+ "name": "quality_getQualityDocuments",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality documents",
+ "paramCount": 3
+ },
+ {
+ "name": "quality_getQualityDocumentsList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality documents list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getQualityFiles",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get quality files",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getRequiredActionsList",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get required actions list",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_getRequiredActions",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get required actions",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_getRequiredAction",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get required action",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getRisk",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get risk",
+ "paramCount": 1
+ },
+ {
+ "name": "quality_getRisks",
+ "module": "quality",
+ "classification": "READ",
+ "description": "get risks",
+ "paramCount": 7
+ },
+ {
+ "name": "quality_insertIssueReviewer",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "insert issue reviewer",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_updateIssueActionProcesses",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update issue action processes",
+ "paramCount": 3
+ },
+ {
+ "name": "quality_updateIssueStatus",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update issue status",
+ "paramCount": 5
+ },
+ {
+ "name": "quality_updateIssueTaskStatus",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update issue task status",
+ "paramCount": 5
+ },
+ {
+ "name": "quality_updateIssueTaskContent",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update issue task content",
+ "paramCount": 4
+ },
+ {
+ "name": "quality_updateQualityDocumentStepOrder",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update quality document step order",
+ "paramCount": 3
+ },
+ {
+ "name": "quality_updateRiskStatus",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "update risk status",
+ "paramCount": 2
+ },
+ {
+ "name": "quality_upsertGauge",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert gauge",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertGaugeCalibrationRecord",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert gauge calibration record",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertGaugeType",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert gauge type",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertIssue",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert issue",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertIssueWorkflow",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert issue workflow",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertIssueType",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert issue type",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertRequiredAction",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert required action",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertQualityDocument",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert quality document",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertQualityDocumentStep",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert quality document step",
+ "paramCount": 0
+ },
+ {
+ "name": "quality_upsertRisk",
+ "module": "quality",
+ "classification": "WRITE",
+ "description": "upsert risk",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_activateWorkCenter",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "activate work center",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteAbility",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete ability",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_deleteContractor",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete contractor",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteEmployeeAbility",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete employee ability",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteFailureMode",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete failure mode",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteLocation",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete location",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceDispatch",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceDispatchComment",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch comment",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceDispatchEvent",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch event",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceDispatchItem",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch item",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceDispatchWorkCenter",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance dispatch work center",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceSchedule",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance schedule",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteMaintenanceScheduleItem",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete maintenance schedule item",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deletePartner",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete partner",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_activateProcess",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "activate process",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_processDeactivate",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "process deactivate",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteProcess",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete process",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteShift",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete shift",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteSuggestion",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete suggestion",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteTraining",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete training",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteTrainingAssignment",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete training assignment",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteTrainingQuestion",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete training question",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_deleteWorkCenter",
+ "module": "resources",
+ "classification": "DESTRUCTIVE",
+ "description": "delete work center",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getAbilities",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get abilities",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getAbilitiesList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get abilities list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getAbility",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get ability",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getContractor",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get contractor",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getContractors",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get contractors",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getEmployeeAbilities",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get employee abilities",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getFailureMode",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get failure mode",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getFailureModes",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get failure modes",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getFailureModesList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get failure modes list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getLocation",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get location",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getLocations",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get locations",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getLocationsList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get locations list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getMaintenanceDispatch",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceDispatchComments",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch comments",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceDispatchEvents",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch events",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceDispatchItems",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch items",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceDispatchItemTrackedEntities",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch item tracked entities",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceDispatches",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatches",
+ "paramCount": 5
+ },
+ {
+ "name": "resources_getMaintenanceDispatchesByLocation",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatches by location",
+ "paramCount": 6
+ },
+ {
+ "name": "resources_getMaintenanceDispatchWorkCenters",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance dispatch work centers",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceSchedule",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance schedule",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceScheduleItems",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance schedule items",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getMaintenanceSchedules",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance schedules",
+ "paramCount": 5
+ },
+ {
+ "name": "resources_getMaintenanceSchedulesByLocation",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get maintenance schedules by location",
+ "paramCount": 6
+ },
+ {
+ "name": "resources_getOutstandingTrainingsForUser",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get outstanding trainings for user",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getPartner",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get partner",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_getPartnerBySupplierId",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get partner by supplier id",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getPartners",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get partners",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getProcess",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get process",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getProcesses",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get processes",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getProcessesList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get processes list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getSuggestion",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get suggestion",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getSuggestions",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get suggestions",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_getTraining",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getTrainingAssignment",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training assignment",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getTrainingAssignmentForCompletion",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training assignment for completion",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getTrainingAssignments",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training assignments",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getTrainingAssignmentStatus",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training assignment status",
+ "paramCount": 3
+ },
+ {
+ "name": "resources_getTrainingAssignmentSummary",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training assignment summary",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getTrainingQuestions",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get training questions",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getTrainings",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get trainings",
+ "paramCount": 3
+ },
+ {
+ "name": "resources_getTrainingsList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get trainings list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getWorkCenter",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get work center",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getWorkCenters",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get work centers",
+ "paramCount": 3
+ },
+ {
+ "name": "resources_getWorkCentersByLocation",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get work centers by location",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_getWorkCentersList",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get work centers list",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_getWorkCentersListWithBlockingStatus",
+ "module": "resources",
+ "classification": "READ",
+ "description": "get work centers list with blocking status",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_insertAbility",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "insert ability",
+ "paramCount": 7
+ },
+ {
+ "name": "resources_insertEmployeeAbilities",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "insert employee abilities",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_insertTrainingCompletion",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "insert training completion",
+ "paramCount": 5
+ },
+ {
+ "name": "resources_updateAbility",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "update ability",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_updateSuggestionEmoji",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "update suggestion emoji",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_updateSuggestionTags",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "update suggestion tags",
+ "paramCount": 2
+ },
+ {
+ "name": "resources_updateTrainingQuestionOrder",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "update training question order",
+ "paramCount": 3
+ },
+ {
+ "name": "resources_upsertContractor",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert contractor",
+ "paramCount": 1
+ },
+ {
+ "name": "resources_upsertEmployeeAbility",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert employee ability",
+ "paramCount": 6
+ },
+ {
+ "name": "resources_upsertFailureMode",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert failure mode",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertLocation",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert location",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceDispatch",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceDispatchComment",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch comment",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceDispatchEvent",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch event",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceDispatchItem",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch item",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceDispatchWorkCenter",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance dispatch work center",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceSchedule",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance schedule",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertMaintenanceScheduleItem",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert maintenance schedule item",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertPartner",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert partner",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertProcess",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert process",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertTraining",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert training",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertTrainingAssignment",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert training assignment",
+ "paramCount": 4
+ },
+ {
+ "name": "resources_upsertTrainingQuestion",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert training question",
+ "paramCount": 0
+ },
+ {
+ "name": "resources_upsertWorkCenter",
+ "module": "resources",
+ "classification": "WRITE",
+ "description": "upsert work center",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_closeSalesOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "close sales order",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_convertSalesRfqToQuote",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "convert sales rfq to quote",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_convertQuoteToOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "convert quote to order",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_copyQuoteLine",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "copy quote line",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_copyQuote",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "copy quote",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_deleteCustomer",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteCustomerContact",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer contact",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_deleteCustomerLocation",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer location",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_deleteCustomerStatus",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer status",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteCustomerType",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer type",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteNoQuoteReason",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete no quote reason",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuote",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteMakeMethod",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote make method",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteLine",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteMaterial",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote material",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteOperation",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote operation",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteOperationStep",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote operation step",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteOperationParameter",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote operation parameter",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteQuoteOperationTool",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete quote operation tool",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteSalesOrder",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales order",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteSalesOrderLine",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales order line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteSalesRFQ",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales r f q",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_deleteSalesRFQLine",
+ "module": "sales",
+ "classification": "DESTRUCTIVE",
+ "description": "delete sales r f q line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getConfigurationParametersByQuoteLineId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get configuration parameters by quote line id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomer",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerContact",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer contact",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerContacts",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer contacts",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerLocation",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer location",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerLocations",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer locations",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerPayment",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer payment",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerShipping",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer shipping",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomers",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customers",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getCustomersList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customers list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getCustomerStatus",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer status",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerStatuses",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer statuses",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getCustomerStatusesList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer statuses list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getCustomerType",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer type",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getCustomerTypes",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer types",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getCustomerTypesList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get customer types list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getExternalSalesOrderLines",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get external sales order lines",
+ "paramCount": 5
+ },
+ {
+ "name": "sales_getModelByQuoteLineId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get model by quote line id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getNoQuoteReasonsList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get no quote reasons list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getNoQuoteReason",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get no quote reason",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getNoQuoteReasons",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get no quote reasons",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getOpportunity",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get opportunity",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getOpportunityDocuments",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get opportunity documents",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getOpportunityLineDocuments",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get opportunity line documents",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_getQuote",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteFavorites",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote favorites",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getQuotes",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quotes",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getQuotesList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quotes list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getQuoteAssembliesByLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote assemblies by line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteAssemblies",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote assemblies",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteCustomerDetails",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote customer details",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLinesList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote lines list",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMakeMethod",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote make method",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getRootQuoteMakeMethod",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get root quote make method",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMethodTrees",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote method trees",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMethodTreeArray",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote method tree array",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLines",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote lines",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteByExternalId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote by external id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLinePrices",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote line prices",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLinePricesByQuoteId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote line prices by quote id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteLinePricesByItemId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote line prices by item id",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_getQuoteLinePricesByItemIds",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote line prices by item ids",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_getQuoteMaterials",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote materials",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMaterial",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote material",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMaterialsByLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote materials by line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMaterialsByMethodId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote materials by method id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteMaterialsByOperation",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote materials by operation",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteOperation",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote operation",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteOperationsByLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote operations by line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteOperationsByMethodId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote operations by method id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteOperations",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote operations",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuotePayment",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote payment",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getQuoteShipment",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get quote shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getRelatedPricesForQuoteLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get related prices for quote line",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_getSalesDocumentsAssignedToMe",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales documents assigned to me",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesOrder",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderCustomerDetails",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order customer details",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderFavorites",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order favorites",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesOrderRelatedItems",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order related items",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_getSalesOrders",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales orders",
+ "paramCount": 6
+ },
+ {
+ "name": "sales_getSalesOrdersList",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales orders list",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesOrderPayment",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order payment",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesTerms",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales terms",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesOrderShipment",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order shipment",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderCustomers",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order customers",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesOrderLines",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order lines",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderInvoiceLines",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order invoice lines",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderInvoicesByIds",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order invoices by ids",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderLinesByItemId",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order lines by item id",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderLinesByItemIds",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order lines by item ids",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesOrderLineShipments",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales order line shipments",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesRFQ",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales r f q",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesRFQFavorites",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales r f q favorites",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_getSalesRFQs",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales r f qs",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_getSalesRFQLine",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales r f q line",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_getSalesRFQLines",
+ "module": "sales",
+ "classification": "READ",
+ "description": "get sales r f q lines",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_insertCustomerContact",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "insert customer contact",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_insertCustomerLocation",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "insert customer location",
+ "paramCount": 11
+ },
+ {
+ "name": "sales_insertSalesOrderLines",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "insert sales order lines",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_finalizeQuote",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "finalize quote",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_releaseSalesOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "release sales order",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_upsertCustomer",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert customer",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateCustomerAccounting",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update customer accounting",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateCustomerContact",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update customer contact",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateCustomerLocation",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update customer location",
+ "paramCount": 11
+ },
+ {
+ "name": "sales_updateCustomerPayment",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update customer payment",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateCustomerShipping",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update customer shipping",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertCustomerStatus",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert customer status",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertCustomerType",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert customer type",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertNoQuoteReason",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert no quote reason",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateSalesRFQFavorite",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales r f q favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateSalesRFQLineOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales r f q line order",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateQuoteExchangeRate",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateQuoteLinePrecision",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote line precision",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_updateSalesOrderExchangeRate",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales order exchange rate",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateQuoteFavorite",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateSalesRFQStatus",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales r f q status",
+ "paramCount": 5
+ },
+ {
+ "name": "sales_updateQuoteMaterialOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote material order",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateQuoteOperationOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote operation order",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateQuoteStatus",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update quote status",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_upsertMakeMethodFromQuoteLine",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert make method from quote line",
+ "paramCount": 11
+ },
+ {
+ "name": "sales_upsertMakeMethodFromQuoteMethod",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert make method from quote method",
+ "paramCount": 10
+ },
+ {
+ "name": "sales_upsertQuote",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteLine",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote line",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteLineAdditionalCharges",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote line additional charges",
+ "paramCount": 1
+ },
+ {
+ "name": "sales_upsertQuoteLinePrices",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote line prices",
+ "paramCount": 9
+ },
+ {
+ "name": "sales_calculatePricesForQuantities",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "calculate prices for quantities",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_recalculateQuoteLinePrices",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "recalculate quote line prices",
+ "paramCount": 2
+ },
+ {
+ "name": "sales_upsertQuoteLineMethod",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote line method",
+ "paramCount": 12
+ },
+ {
+ "name": "sales_upsertQuoteMaterial",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote material",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteMaterialMakeMethod",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote material make method",
+ "paramCount": 11
+ },
+ {
+ "name": "sales_upsertQuoteOperation",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote operation",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteOperationStep",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote operation step",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteOperationParameter",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote operation parameter",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteOperationTool",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote operation tool",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuotePayment",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote payment",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertQuoteShipment",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert quote shipment",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_updateSalesOrderFavorite",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales order favorite",
+ "paramCount": 3
+ },
+ {
+ "name": "sales_updateSalesOrderStatus",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "update sales order status",
+ "paramCount": 4
+ },
+ {
+ "name": "sales_upsertSalesOrder",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales order",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertSalesOrderShipment",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales order shipment",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertSalesOrderLine",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales order line",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertSalesOrderPayment",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales order payment",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertSalesRFQ",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales r f q",
+ "paramCount": 0
+ },
+ {
+ "name": "sales_upsertSalesRFQLine",
+ "module": "sales",
+ "classification": "WRITE",
+ "description": "upsert sales r f q line",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getAccountsPayableBillingAddress",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get accounts payable billing address",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getAccountsReceivableBillingAddress",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get accounts receivable billing address",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_updateAccountsPayableBillingAddress",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts payable billing address",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_updateAccountsReceivableBillingAddress",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts receivable billing address",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_deleteApiKey",
+ "module": "settings",
+ "classification": "DESTRUCTIVE",
+ "description": "delete api key",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_deleteWebhook",
+ "module": "settings",
+ "classification": "DESTRUCTIVE",
+ "description": "delete webhook",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_deactivateWebhooks",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "deactivate webhooks",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getApiKeys",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get api keys",
+ "paramCount": 4
+ },
+ {
+ "name": "settings_getCompanies",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get companies",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getCompany",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get company",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getCompanyPlan",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get company plan",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getCompanySettings",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get company settings",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getCompanyIntegrations",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get company integrations",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getConfig",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get config",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getCurrentSequence",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get current sequence",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getCustomField",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get custom field",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getCustomFields",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get custom fields",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getCustomFieldsTables",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get custom fields tables",
+ "paramCount": 4
+ },
+ {
+ "name": "settings_getIntegration",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get integration",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getIntegrations",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get integrations",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getKanbanOutputSetting",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get kanban output setting",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getPlanById",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get plan by id",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getPlans",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get plans",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getNextSequence",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get next sequence",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getSequence",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get sequence",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getSequences",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get sequences",
+ "paramCount": 4
+ },
+ {
+ "name": "settings_getSequencesList",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get sequences list",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getTerms",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get terms",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getWebhook",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get webhook",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_getWebhookTables",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get webhook tables",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_getWebhooks",
+ "module": "settings",
+ "classification": "READ",
+ "description": "get webhooks",
+ "paramCount": 4
+ },
+ {
+ "name": "settings_insertCompany",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "insert company",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateCompanyPlan",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update company plan",
+ "paramCount": 5
+ },
+ {
+ "name": "settings_updateCompany",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update company",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_updateKanbanOutputSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update kanban output setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateMetricSettings",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update metric settings",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_upsertApiKey",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "upsert api key",
+ "paramCount": 0
+ },
+ {
+ "name": "settings_updateDigitalQuoteSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update digital quote setting",
+ "paramCount": 3
+ },
+ {
+ "name": "settings_updateLogoDark",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update logo dark",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateLogoLight",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update logo light",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateLogoDarkIcon",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update logo dark icon",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateLogoLightIcon",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update logo light icon",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateMaterialGeneratedIdsSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update material generated ids setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateMaterialUnitsSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update material units setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateProductLabelSize",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update product label size",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updatePurchasingPdfThumbnails",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update purchasing pdf thumbnails",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateSalesPdfThumbnails",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update sales pdf thumbnails",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateJobTravelerWorkInstructions",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update job traveler work instructions",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateTimeCardSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update time card setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateConsoleSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update console setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateRfqReadySetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update rfq ready setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateSuggestionNotificationSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update suggestion notification setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateMaintenanceDispatchNotificationSettings",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update maintenance dispatch notification settings",
+ "paramCount": 5
+ },
+ {
+ "name": "settings_updateSupplierQuoteNotificationSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update supplier quote notification setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updatePurchasePriceUpdateTimingSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update purchase price update timing setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateLeadTimesOnReceiptSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update lead times on receipt setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateSupplierApprovalSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update supplier approval setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateAccountsPayableAddressSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts payable address setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateAccountsReceivableAddressSetting",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts receivable address setting",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateAccountsPayableEmail",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts payable email",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateAccountsReceivableEmail",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update accounts receivable email",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateDefaultSupplierCc",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update default supplier cc",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateDefaultCustomerCc",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update default customer cc",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateQuoteLineCategoryMarkups",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update quote line category markups",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateSequence",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update sequence",
+ "paramCount": 1
+ },
+ {
+ "name": "settings_updateIntegrationMetadata",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "update integration metadata",
+ "paramCount": 2
+ },
+ {
+ "name": "settings_upsertWebhook",
+ "module": "settings",
+ "classification": "WRITE",
+ "description": "upsert webhook",
+ "paramCount": 0
+ },
+ {
+ "name": "shared_approveRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "approve request",
+ "paramCount": 3
+ },
+ {
+ "name": "shared_canApproveRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "can approve request",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_canApproveRequestInWindow",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "can approve request in window",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_cancelApprovalRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "cancel approval request",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_canViewApprovalRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "can view approval request",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_createApprovalRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "create approval request",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_deleteApprovalRule",
+ "module": "shared",
+ "classification": "DESTRUCTIVE",
+ "description": "delete approval rule",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_deleteNote",
+ "module": "shared",
+ "classification": "DESTRUCTIVE",
+ "description": "delete note",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_deleteSavedView",
+ "module": "shared",
+ "classification": "DESTRUCTIVE",
+ "description": "delete saved view",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_generateEmbedding",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "generate embedding",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getApprovalById",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval by id",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getApprovalRequestsByDocument",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval requests by document",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_getApprovalRuleByAmount",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval rule by amount",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_getApproverUserIdsForRule",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approver user ids for rule",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getApprovalRuleById",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval rule by id",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getApprovalRules",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval rules",
+ "paramCount": 0
+ },
+ {
+ "name": "shared_getApprovalRulesForApprover",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approval rules for approver",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getApprovalsForUser",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get approvals for user",
+ "paramCount": 3
+ },
+ {
+ "name": "shared_getBase64ImageFromSupabase",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get base64 image from supabase",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getCountries",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get countries",
+ "paramCount": 0
+ },
+ {
+ "name": "shared_getLatestApprovalRequestForDocument",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get latest approval request for document",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_getModelByItemId",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get model by item id",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getNotes",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get notes",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getPendingApprovalsForApprover",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get pending approvals for approver",
+ "paramCount": 0
+ },
+ {
+ "name": "shared_getPeriods",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get periods",
+ "paramCount": 3
+ },
+ {
+ "name": "shared_getSavedViews",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get saved views",
+ "paramCount": 0
+ },
+ {
+ "name": "shared_getTagsList",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get tags list",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_hasPendingApproval",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "has pending approval",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_importCsv",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "import csv",
+ "paramCount": 5
+ },
+ {
+ "name": "shared_insertNote",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "insert note",
+ "paramCount": 3
+ },
+ {
+ "name": "shared_insertTag",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "insert tag",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_isApprovalRequired",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "is approval required",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_getExternalLink",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get external link",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_upsertExternalLink",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "upsert external link",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_getCustomerPortals",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get customer portals",
+ "paramCount": 4
+ },
+ {
+ "name": "shared_getCustomerPortal",
+ "module": "shared",
+ "classification": "READ",
+ "description": "get customer portal",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_deleteCustomerPortal",
+ "module": "shared",
+ "classification": "DESTRUCTIVE",
+ "description": "delete customer portal",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_updateModelThumbnail",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "update model thumbnail",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_upsertModelUpload",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "upsert model upload",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_updateNote",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "update note",
+ "paramCount": 2
+ },
+ {
+ "name": "shared_rejectRequest",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "reject request",
+ "paramCount": 3
+ },
+ {
+ "name": "shared_upsertApprovalRule",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "upsert approval rule",
+ "paramCount": 1
+ },
+ {
+ "name": "shared_upsertSavedView",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "upsert saved view",
+ "paramCount": 11
+ },
+ {
+ "name": "shared_updateSavedViewOrder",
+ "module": "shared",
+ "classification": "WRITE",
+ "description": "update saved view order",
+ "paramCount": 3
+ },
+ {
+ "name": "users_deleteEmployeeType",
+ "module": "users",
+ "classification": "DESTRUCTIVE",
+ "description": "delete employee type",
+ "paramCount": 1
+ },
+ {
+ "name": "users_deleteGroup",
+ "module": "users",
+ "classification": "DESTRUCTIVE",
+ "description": "delete group",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getCompaniesForUser",
+ "module": "users",
+ "classification": "READ",
+ "description": "get companies for user",
+ "paramCount": 0
+ },
+ {
+ "name": "users_getCustomers",
+ "module": "users",
+ "classification": "READ",
+ "description": "get customers",
+ "paramCount": 4
+ },
+ {
+ "name": "users_getEmployee",
+ "module": "users",
+ "classification": "READ",
+ "description": "get employee",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getEmployees",
+ "module": "users",
+ "classification": "READ",
+ "description": "get employees",
+ "paramCount": 4
+ },
+ {
+ "name": "users_getConsoleOperators",
+ "module": "users",
+ "classification": "READ",
+ "description": "get console operators",
+ "paramCount": 4
+ },
+ {
+ "name": "users_getEmployeeType",
+ "module": "users",
+ "classification": "READ",
+ "description": "get employee type",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getEmployeeTypes",
+ "module": "users",
+ "classification": "READ",
+ "description": "get employee types",
+ "paramCount": 4
+ },
+ {
+ "name": "users_getInvitable",
+ "module": "users",
+ "classification": "READ",
+ "description": "get invitable",
+ "paramCount": 0
+ },
+ {
+ "name": "users_getModules",
+ "module": "users",
+ "classification": "READ",
+ "description": "get modules",
+ "paramCount": 0
+ },
+ {
+ "name": "users_getGroup",
+ "module": "users",
+ "classification": "READ",
+ "description": "get group",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getGroupMembers",
+ "module": "users",
+ "classification": "READ",
+ "description": "get group members",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getGroups",
+ "module": "users",
+ "classification": "READ",
+ "description": "get groups",
+ "paramCount": 5
+ },
+ {
+ "name": "users_getGroupEmails",
+ "module": "users",
+ "classification": "READ",
+ "description": "get group emails",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getPermissionsByEmployeeType",
+ "module": "users",
+ "classification": "READ",
+ "description": "get permissions by employee type",
+ "paramCount": 1
+ },
+ {
+ "name": "users_getSuppliers",
+ "module": "users",
+ "classification": "READ",
+ "description": "get suppliers",
+ "paramCount": 4
+ },
+ {
+ "name": "users_getUsers",
+ "module": "users",
+ "classification": "READ",
+ "description": "get users",
+ "paramCount": 0
+ },
+ {
+ "name": "users_getUserEmails",
+ "module": "users",
+ "classification": "READ",
+ "description": "get user emails",
+ "paramCount": 1
+ },
+ {
+ "name": "users_insertEmployeeType",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "insert employee type",
+ "paramCount": 2
+ },
+ {
+ "name": "users_insertGroup",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "insert group",
+ "paramCount": 2
+ },
+ {
+ "name": "users_upsertEmployeeType",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "upsert employee type",
+ "paramCount": 1
+ },
+ {
+ "name": "users_upsertEmployeeTypePermissions",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "upsert employee type permissions",
+ "paramCount": 4
+ },
+ {
+ "name": "users_upsertGroup",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "upsert group",
+ "paramCount": 3
+ },
+ {
+ "name": "users_upsertGroupMembers",
+ "module": "users",
+ "classification": "WRITE",
+ "description": "upsert group members",
+ "paramCount": 2
+ }
+ ]
+}
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/account.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/account.ts
index 211a760313..542b015fd7 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/account.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/account.ts
@@ -27,12 +27,12 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_deleteUserAttributeValue",
{
description: "delete user attribute value",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
userAttributeId: z.string(),
userAttributeValueId: z.string()
}),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -45,9 +45,9 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getAccount",
{
description: "get account",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -60,9 +60,9 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getAttributes",
{
description: "get attributes",
- inputSchema: {
+ inputSchema: z.object({
isPublic: z.boolean(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -75,7 +75,7 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getPrivateAttributes",
{
description: "get private attributes",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -88,7 +88,7 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getPublicAttributes",
{
description: "get public attributes",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -101,7 +101,7 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getAllAttributeCategories",
{
description: "get all attribute categories",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -114,9 +114,9 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_getAttributeCategoryWithValues",
{
description: "get attribute category with values",
- inputSchema: {
+ inputSchema: z.object({
categoryId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -129,9 +129,9 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_updateAvatar",
{
description: "update avatar",
- inputSchema: {
+ inputSchema: z.object({
avatarUrl: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -144,14 +144,14 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_updatePublicAccount",
{
description: "update public account",
- inputSchema: {
+ inputSchema: z.object({
account: z.object({
id: z.string(),
firstName: z.string(),
lastName: z.string(),
about: z.string().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -164,14 +164,14 @@ export const registerAccountTools: RegisterTools = (server, ctx) => {
"account_upsertUserAttributeValue",
{
description: "upsert user attribute value",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
userAttributeValueId: z.any().optional(),
userAttributeId: z.string(),
value: z.any(),
type: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/accounting.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/accounting.ts
index d64b3fe4f3..f87c59d870 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/accounting.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/accounting.ts
@@ -66,9 +66,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_deleteAccount",
{
description: "delete account",
- inputSchema: {
+ inputSchema: z.object({
accountId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -81,9 +81,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_deleteAccountCategory",
{
description: "delete account category",
- inputSchema: {
+ inputSchema: z.object({
accountCategoryId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -96,9 +96,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_deleteAccountSubcategory",
{
description: "delete account subcategory",
- inputSchema: {
+ inputSchema: z.object({
accountSubcategoryId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -111,9 +111,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_deletePaymentTerm",
{
description: "delete payment term",
- inputSchema: {
+ inputSchema: z.object({
paymentTermId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -126,9 +126,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccount",
{
description: "get account",
- inputSchema: {
+ inputSchema: z.object({
accountId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -141,13 +141,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccounts",
{
description: "get accounts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -160,13 +160,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountsList",
{
description: "get accounts list",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
type: z.any().optional(),
incomeBalance: z.any().optional(),
classes: z.array(z.any()).optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -179,13 +179,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountCategories",
{
description: "get account categories",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -198,7 +198,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountCategoriesList",
{
description: "get account categories list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -211,9 +211,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountCategory",
{
description: "get account category",
- inputSchema: {
+ inputSchema: z.object({
accountCategoryId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -226,13 +226,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountSubcategories",
{
description: "get account subcategories",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -245,9 +245,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountSubcategoriesByCategory",
{
description: "get account subcategories by category",
- inputSchema: {
+ inputSchema: z.object({
accountCategoryId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -260,9 +260,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getAccountSubcategory",
{
description: "get account subcategory",
- inputSchema: {
+ inputSchema: z.object({
accountSubcategoryId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -275,7 +275,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getBaseCurrency",
{
description: "get base currency",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -288,7 +288,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getChartOfAccounts",
{
description: "get chart of accounts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -297,7 +297,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
startDate: z.string().nullable(),
endDate: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -310,9 +310,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getCurrency",
{
description: "get currency",
- inputSchema: {
+ inputSchema: z.object({
currencyId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -325,9 +325,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getCurrencyByCode",
{
description: "get currency by code",
- inputSchema: {
+ inputSchema: z.object({
currencyCode: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -340,13 +340,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getCurrencies",
{
description: "get currencies",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -359,7 +359,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getCurrenciesList",
{
description: "get currencies list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -372,9 +372,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getCurrentAccountingPeriod",
{
description: "get current accounting period",
- inputSchema: {
+ inputSchema: z.object({
date: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -387,7 +387,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getDefaultAccounts",
{
description: "get default accounts",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -400,7 +400,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getFiscalYearSettings",
{
description: "get fiscal year settings",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -413,12 +413,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getInventoryPostingGroup",
{
description: "get inventory posting group",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
itemPostingGroupId: z.string().nullable(),
locationId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -431,12 +431,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getInventoryPostingGroups",
{
description: "get inventory posting groups",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -449,9 +449,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPaymentTerm",
{
description: "get payment term",
- inputSchema: {
+ inputSchema: z.object({
paymentTermId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -464,13 +464,13 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPaymentTerms",
{
description: "get payment terms",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -483,7 +483,7 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPaymentTermsList",
{
description: "get payment terms list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -496,12 +496,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPurchasingPostingGroup",
{
description: "get purchasing posting group",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
itemPostingGroupId: z.string().nullable(),
supplierTypeId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -514,12 +514,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPurchasingPostingGroups",
{
description: "get purchasing posting groups",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -532,12 +532,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getPurchasingSalesGroup",
{
description: "get purchasing sales group",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
itemPostingGroupId: z.string().nullable(),
customerTypeId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -550,12 +550,12 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_getSalesPostingGroups",
{
description: "get sales posting groups",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -568,9 +568,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_updateDefaultBalanceSheetAccounts",
{
description: "update default balance sheet accounts",
- inputSchema: {
+ inputSchema: z.object({
defaultAccounts: defaultBalanceSheetAccountValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -583,9 +583,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_updateDefaultIncomeAccounts",
{
description: "update default income accounts",
- inputSchema: {
+ inputSchema: z.object({
defaultAccounts: defaultIncomeAcountValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -598,9 +598,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_updateFiscalYearSettings",
{
description: "update fiscal year settings",
- inputSchema: {
+ inputSchema: z.object({
fiscalYearSettings: fiscalYearSettingsValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -613,9 +613,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_upsertAccount",
{
description: "upsert account",
- inputSchema: {
+ inputSchema: z.object({
account: accountValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -628,9 +628,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_upsertAccountCategory",
{
description: "upsert account category",
- inputSchema: {
+ inputSchema: z.object({
accountCategory: accountCategoryValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -643,9 +643,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_upsertAccountSubcategory",
{
description: "upsert account subcategory",
- inputSchema: {
+ inputSchema: z.object({
accountSubcategory: accountSubcategoryValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -658,9 +658,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_upsertCurrency",
{
description: "upsert currency",
- inputSchema: {
+ inputSchema: z.object({
currency: currencyValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -673,9 +673,9 @@ export const registerAccountingTools: RegisterTools = (server, ctx) => {
"accounting_upsertPaymentTerm",
{
description: "upsert payment term",
- inputSchema: {
+ inputSchema: z.object({
paymentTerm: paymentTermValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/documents.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/documents.ts
index 2ea2e877a5..44040d082f 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/documents.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/documents.ts
@@ -35,9 +35,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_deleteDocument",
{
description: "delete document",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -50,9 +50,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_deleteDocumentFavorite",
{
description: "delete document favorite",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -65,10 +65,10 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_deleteDocumentLabel",
{
description: "delete document label",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
label: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -81,9 +81,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_getDocument",
{
description: "get document",
- inputSchema: {
+ inputSchema: z.object({
documentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -96,7 +96,7 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_getDocuments",
{
description: "get documents",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -105,7 +105,7 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
recent: z.boolean().optional(),
active: z.boolean()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -118,7 +118,7 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_getDocumentExtensions",
{
description: "get document extensions",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -131,7 +131,7 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_getDocumentLabels",
{
description: "get document labels",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -144,9 +144,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_insertDocumentFavorite",
{
description: "insert document favorite",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -159,10 +159,10 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_insertDocumentLabel",
{
description: "insert document label",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
label: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -175,9 +175,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_moveDocumentToTrash",
{
description: "move document to trash",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -190,9 +190,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_restoreDocument",
{
description: "restore document",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -205,9 +205,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_upsertDocument",
{
description: "upsert document",
- inputSchema: {
+ inputSchema: z.object({
document: documentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -220,12 +220,12 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_updateDocumentFavorite",
{
description: "update document favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -238,9 +238,9 @@ export const registerDocumentsTools: RegisterTools = (server, ctx) => {
"documents_updateDocumentLabels",
{
description: "update document labels",
- inputSchema: {
+ inputSchema: z.object({
document: documentLabelsValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/inventory.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/inventory.ts
index e1b2457581..318d884f9a 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/inventory.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/inventory.ts
@@ -102,9 +102,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteBatchProperty",
{
description: "delete batch property",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -117,9 +117,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteKanban",
{
description: "delete kanban",
- inputSchema: {
+ inputSchema: z.object({
kanbanId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -132,9 +132,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteReceipt",
{
description: "delete receipt",
- inputSchema: {
+ inputSchema: z.object({
receiptId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -147,9 +147,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteReceiptLine",
{
description: "delete receipt line",
- inputSchema: {
+ inputSchema: z.object({
receiptLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -162,9 +162,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteShelf",
{
description: "delete shelf",
- inputSchema: {
+ inputSchema: z.object({
shelfId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -177,9 +177,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteShipment",
{
description: "delete shipment",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -192,9 +192,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteShipmentLine",
{
description: "delete shipment line",
- inputSchema: {
+ inputSchema: z.object({
shipmentLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -207,9 +207,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteShippingMethod",
{
description: "delete shipping method",
- inputSchema: {
+ inputSchema: z.object({
shippingMethodId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -222,9 +222,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteStockTransfer",
{
description: "delete stock transfer",
- inputSchema: {
+ inputSchema: z.object({
stockTransferId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -237,9 +237,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteStockTransferLine",
{
description: "delete stock transfer line",
- inputSchema: {
+ inputSchema: z.object({
stockTransferLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -252,9 +252,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteWarehouseTransfer",
{
description: "delete warehouse transfer",
- inputSchema: {
+ inputSchema: z.object({
transferId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -267,9 +267,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_deleteWarehouseTransferLine",
{
description: "delete warehouse transfer line",
- inputSchema: {
+ inputSchema: z.object({
transferLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -282,12 +282,12 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getItemLedgerPage",
{
description: "get item ledger page",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
sortDescending: z.boolean().optional(),
page: z.number().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -300,9 +300,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getBatchProperties",
{
description: "get batch properties",
- inputSchema: {
+ inputSchema: z.object({
itemIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -315,14 +315,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getInventoryItems",
{
description: "get inventory items",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -335,14 +335,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getInventoryItemsCount",
{
description: "get inventory items count",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -355,14 +355,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getKanbans",
{
description: "get kanbans",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -375,9 +375,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getKanban",
{
description: "get kanban",
- inputSchema: {
+ inputSchema: z.object({
kanbanId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -390,9 +390,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getStockTransfer",
{
description: "get stock transfer",
- inputSchema: {
+ inputSchema: z.object({
stockTransferId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -405,9 +405,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getStockTransferLine",
{
description: "get stock transfer line",
- inputSchema: {
+ inputSchema: z.object({
stockTransferLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -420,9 +420,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getStockTransferLines",
{
description: "get stock transfer lines",
- inputSchema: {
+ inputSchema: z.object({
stockTransferId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -435,9 +435,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getStockTransferTracking",
{
description: "get stock transfer tracking",
- inputSchema: {
+ inputSchema: z.object({
stockTransferId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -450,14 +450,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getStockTransfers",
{
description: "get stock transfers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
locationId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -470,10 +470,10 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getDefaultShelfOrShelfWithHighestQuantity",
{
description: "get default shelf or shelf with highest quantity",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -486,13 +486,13 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceipts",
{
description: "get receipts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -505,9 +505,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceipt",
{
description: "get receipt",
- inputSchema: {
+ inputSchema: z.object({
receiptId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -520,9 +520,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceiptLines",
{
description: "get receipt lines",
- inputSchema: {
+ inputSchema: z.object({
receiptId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -535,9 +535,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceiptTracking",
{
description: "get receipt tracking",
- inputSchema: {
+ inputSchema: z.object({
receiptId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -550,9 +550,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceiptLineTracking",
{
description: "get receipt line tracking",
- inputSchema: {
+ inputSchema: z.object({
receiptLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -565,9 +565,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getReceiptFiles",
{
description: "get receipt files",
- inputSchema: {
+ inputSchema: z.object({
lineIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -580,11 +580,11 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getSerialNumbersForItem",
{
description: "get serial numbers for item",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
itemId: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -597,12 +597,12 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getBatchNumbersForItem",
{
description: "get batch numbers for item",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
itemId: z.string(),
isReadOnly: z.boolean().optional()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -615,7 +615,7 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShelvesList",
{
description: "get shelves list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -628,9 +628,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShelvesListForLocation",
{
description: "get shelves list for location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -643,14 +643,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShelves",
{
description: "get shelves",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -663,9 +663,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShelf",
{
description: "get shelf",
- inputSchema: {
+ inputSchema: z.object({
shelfId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -678,13 +678,13 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipments",
{
description: "get shipments",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -697,9 +697,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipment",
{
description: "get shipment",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -712,9 +712,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentLines",
{
description: "get shipment lines",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -727,9 +727,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentLinesWithDetails",
{
description: "get shipment lines with details",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -742,9 +742,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentFiles",
{
description: "get shipment files",
- inputSchema: {
+ inputSchema: z.object({
lineIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -757,10 +757,10 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentRelatedItems",
{
description: "get shipment related items",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
sourceDocumentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -773,9 +773,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentTracking",
{
description: "get shipment tracking",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -788,9 +788,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShipmentLineTracking",
{
description: "get shipment line tracking",
- inputSchema: {
+ inputSchema: z.object({
shipmentLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -803,9 +803,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShippingMethod",
{
description: "get shipping method",
- inputSchema: {
+ inputSchema: z.object({
shippingMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -818,13 +818,13 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShippingMethods",
{
description: "get shipping methods",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -837,7 +837,7 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShippingMethodsList",
{
description: "get shipping methods list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -850,7 +850,7 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getShippingTermsList",
{
description: "get shipping terms list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -863,13 +863,13 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getTrackedEntities",
{
description: "get tracked entities",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -882,9 +882,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getTrackedEntitiesByMakeMethodId",
{
description: "get tracked entities by make method id",
- inputSchema: {
+ inputSchema: z.object({
jobMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -897,9 +897,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getTrackedEntity",
{
description: "get tracked entity",
- inputSchema: {
+ inputSchema: z.object({
trackedEntityId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -912,9 +912,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getTrackedEntitiesByOperationId",
{
description: "get tracked entities by operation id",
- inputSchema: {
+ inputSchema: z.object({
operationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -927,13 +927,13 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getWarehouseTransfers",
{
description: "get warehouse transfers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -946,9 +946,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getWarehouseTransfer",
{
description: "get warehouse transfer",
- inputSchema: {
+ inputSchema: z.object({
transferId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -961,10 +961,10 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getWarehouseTransferLine",
{
description: "get warehouse transfer line",
- inputSchema: {
+ inputSchema: z.object({
transferId: z.string(),
lineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -977,9 +977,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getWarehouseTransferLines",
{
description: "get warehouse transfer lines",
- inputSchema: {
+ inputSchema: z.object({
transferId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -992,9 +992,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_insertManualInventoryAdjustment",
{
description: "insert manual inventory adjustment",
- inputSchema: {
+ inputSchema: z.object({
inventoryAdjustment: inventoryAdjustmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1007,9 +1007,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_updateBatchPropertyOrder",
{
description: "update batch property order",
- inputSchema: {
+ inputSchema: z.object({
data: batchPropertyOrderValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1022,14 +1022,14 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_updateStockTransferStatus",
{
description: "update stock transfer status",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
status: z.any(),
assignee: z.string().nullable().optional(),
completedAt: z.string().nullable()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1042,9 +1042,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertBatchProperty",
{
description: "upsert batch property",
- inputSchema: {
+ inputSchema: z.object({
batchProperty: batchPropertyValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1057,9 +1057,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertKanban",
{
description: "upsert kanban",
- inputSchema: {
+ inputSchema: z.object({
kanban: kanbanValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1072,9 +1072,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertReceipt",
{
description: "upsert receipt",
- inputSchema: {
+ inputSchema: z.object({
receipt: receiptValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1087,9 +1087,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertShelf",
{
description: "upsert shelf",
- inputSchema: {
+ inputSchema: z.object({
shelf: shelfValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1102,9 +1102,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertShippingMethod",
{
description: "upsert shipping method",
- inputSchema: {
+ inputSchema: z.object({
shippingMethod: shippingMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1117,9 +1117,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertShipment",
{
description: "upsert shipment",
- inputSchema: {
+ inputSchema: z.object({
shipment: shipmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1132,9 +1132,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertStockTransfer",
{
description: "upsert stock transfer",
- inputSchema: {
+ inputSchema: z.object({
stockTransfer: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1147,9 +1147,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertStockTransferLine",
{
description: "upsert stock transfer line",
- inputSchema: {
+ inputSchema: z.object({
stockTransferLine: stockTransferLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1162,9 +1162,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertStockTransferLines",
{
description: "upsert stock transfer lines",
- inputSchema: {
+ inputSchema: z.object({
args: stockTransferValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1177,9 +1177,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertWarehouseTransfer",
{
description: "upsert warehouse transfer",
- inputSchema: {
+ inputSchema: z.object({
transfer: warehouseTransferValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1192,10 +1192,10 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_updateWarehouseTransferStatus",
{
description: "update warehouse transfer status",
- inputSchema: {
+ inputSchema: z.object({
transferId: z.string(),
status: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1208,9 +1208,9 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_upsertWarehouseTransferLine",
{
description: "upsert warehouse transfer line",
- inputSchema: {
+ inputSchema: z.object({
line: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1223,10 +1223,10 @@ export const registerInventoryTools: RegisterTools = (server, ctx) => {
"inventory_getDefaultShelfForJob",
{
description: "get default shelf for job",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/invoicing.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/invoicing.ts
index 2515c53b4c..8da9fab367 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/invoicing.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/invoicing.ts
@@ -53,9 +53,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_createPurchaseInvoiceFromPurchaseOrder",
{
description: "create purchase invoice from purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -68,9 +68,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_createSalesInvoiceFromSalesOrder",
{
description: "create sales invoice from sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -83,9 +83,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_createSalesInvoiceFromShipment",
{
description: "create sales invoice from shipment",
- inputSchema: {
+ inputSchema: z.object({
shipmentId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -98,9 +98,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_deletePurchaseInvoice",
{
description: "delete purchase invoice",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -113,9 +113,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_deletePurchaseInvoiceLine",
{
description: "delete purchase invoice line",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -128,9 +128,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_deleteSalesInvoice",
{
description: "delete sales invoice",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -143,9 +143,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_deleteSalesInvoiceLine",
{
description: "delete sales invoice line",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -158,9 +158,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getPurchaseInvoice",
{
description: "get purchase invoice",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -173,14 +173,14 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getPurchaseInvoices",
{
description: "get purchase invoices",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -193,9 +193,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getPurchaseInvoiceDelivery",
{
description: "get purchase invoice delivery",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -208,9 +208,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getPurchaseInvoiceLines",
{
description: "get purchase invoice lines",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -223,9 +223,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getPurchaseInvoiceLine",
{
description: "get purchase invoice line",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -238,9 +238,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoice",
{
description: "get sales invoice",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -253,9 +253,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoiceCustomerDetails",
{
description: "get sales invoice customer details",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -268,14 +268,14 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoices",
{
description: "get sales invoices",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
customerId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -288,9 +288,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoiceShipment",
{
description: "get sales invoice shipment",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -303,9 +303,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoiceLines",
{
description: "get sales invoice lines",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -318,9 +318,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_getSalesInvoiceLine",
{
description: "get sales invoice line",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -333,12 +333,12 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_updatePurchaseInvoiceExchangeRate",
{
description: "update purchase invoice exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -351,13 +351,13 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_updatePurchaseInvoiceStatus",
{
description: "update purchase invoice status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -370,12 +370,12 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_updateSalesInvoiceExchangeRate",
{
description: "update sales invoice exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -388,13 +388,13 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_updateSalesInvoiceStatus",
{
description: "update sales invoice status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -407,9 +407,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertPurchaseInvoice",
{
description: "upsert purchase invoice",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoice: purchaseInvoiceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -422,9 +422,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertPurchaseInvoiceDelivery",
{
description: "upsert purchase invoice delivery",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceDelivery: purchaseInvoiceDeliveryValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -437,9 +437,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertPurchaseInvoiceLine",
{
description: "upsert purchase invoice line",
- inputSchema: {
+ inputSchema: z.object({
purchaseInvoiceLine: purchaseInvoiceLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -452,9 +452,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertSalesInvoice",
{
description: "upsert sales invoice",
- inputSchema: {
+ inputSchema: z.object({
salesInvoice: salesInvoiceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -467,9 +467,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertSalesInvoiceShipment",
{
description: "upsert sales invoice shipment",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceShipment: salesInvoiceShipmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -482,9 +482,9 @@ export const registerInvoicingTools: RegisterTools = (server, ctx) => {
"invoicing_upsertSalesInvoiceLine",
{
description: "upsert sales invoice line",
- inputSchema: {
+ inputSchema: z.object({
salesInvoiceLine: salesInvoiceLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/items.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/items.ts
index d23e041113..242d93bbb6 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/items.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/items.ts
@@ -190,11 +190,11 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_activateMethodVersion",
{
description: "activate method version",
- inputSchema: {
+ inputSchema: z.object({
payload: z.object({
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -207,9 +207,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_copyItem",
{
description: "copy item",
- inputSchema: {
+ inputSchema: z.object({
args: getMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -222,9 +222,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_copyMakeMethod",
{
description: "copy make method",
- inputSchema: {
+ inputSchema: z.object({
args: getMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -237,12 +237,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_createRevision",
{
description: "create revision",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
item: z.any(),
revision: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -255,9 +255,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteConfigurationParameter",
{
description: "delete configuration parameter",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -270,10 +270,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteConfigurationRule",
{
description: "delete configuration rule",
- inputSchema: {
+ inputSchema: z.object({
field: z.string(),
itemId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -286,9 +286,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteItemCustomerPart",
{
description: "delete item customer part",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -301,9 +301,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteConfigurationParameterGroup",
{
description: "delete configuration parameter group",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -316,9 +316,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteItem",
{
description: "delete item",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -331,9 +331,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteItemPostingGroup",
{
description: "delete item posting group",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -346,9 +346,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialDimension",
{
description: "delete material dimension",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -361,9 +361,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialFinish",
{
description: "delete material finish",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -376,9 +376,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialForm",
{
description: "delete material form",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -391,9 +391,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialGrade",
{
description: "delete material grade",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -406,9 +406,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialSubstance",
{
description: "delete material substance",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -421,9 +421,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMethodMaterial",
{
description: "delete method material",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -436,9 +436,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_assertMethodOperationIsDraft",
{
description: "assert method operation is draft",
- inputSchema: {
+ inputSchema: z.object({
operationId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -451,9 +451,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMethodOperationStep",
{
description: "delete method operation step",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -466,9 +466,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMethodOperationParameter",
{
description: "delete method operation parameter",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -481,9 +481,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMethodOperationTool",
{
description: "delete method operation tool",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -496,9 +496,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteUnitOfMeasure",
{
description: "delete unit of measure",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -511,9 +511,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getConfigurationParameters",
{
description: "get configuration parameters",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -526,9 +526,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getConfigurationRules",
{
description: "get configuration rules",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -541,9 +541,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getConsumable",
{
description: "get consumable",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -556,14 +556,14 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getConsumables",
{
description: "get consumables",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -576,7 +576,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getConsumablesList",
{
description: "get consumables list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -589,9 +589,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItem",
{
description: "get item",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -604,9 +604,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemCost",
{
description: "get item cost",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -619,9 +619,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemCostHistory",
{
description: "get item cost history",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -634,9 +634,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemCustomerPart",
{
description: "get item customer part",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -649,9 +649,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemCustomerParts",
{
description: "get item customer parts",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -664,13 +664,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemDemand",
{
description: "get item demand",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string(),
periods: z.array(z.string())
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -683,9 +683,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemFiles",
{
description: "get item files",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -698,9 +698,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemPostingGroup",
{
description: "get item posting group",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -713,13 +713,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemPostingGroups",
{
description: "get item posting groups",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -732,7 +732,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemPostingGroupsList",
{
description: "get item posting groups list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -745,9 +745,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemManufacturing",
{
description: "get item manufacturing",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -760,10 +760,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemPlanning",
{
description: "get item planning",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -776,10 +776,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemQuantities",
{
description: "get item quantities",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -792,9 +792,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemReplenishment",
{
description: "get item replenishment",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -807,10 +807,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemShelfQuantities",
{
description: "get item shelf quantities",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -823,13 +823,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemSupply",
{
description: "get item supply",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string(),
periods: z.array(z.string())
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -842,9 +842,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getItemUnitSalePrice",
{
description: "get item unit sale price",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -857,9 +857,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialUsedIn",
{
description: "get material used in",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -872,9 +872,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMakeMethods",
{
description: "get make methods",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -887,9 +887,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMakeMethodById",
{
description: "get make method by id",
- inputSchema: {
+ inputSchema: z.object({
makeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -902,9 +902,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterial",
{
description: "get material",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -917,14 +917,14 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterials",
{
description: "get materials",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -937,7 +937,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialsList",
{
description: "get materials list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -950,9 +950,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialDimension",
{
description: "get material dimension",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -965,14 +965,14 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialDimensions",
{
description: "get material dimensions",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
isMetric: z.boolean()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -985,10 +985,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialDimensionList",
{
description: "get material dimension list",
- inputSchema: {
+ inputSchema: z.object({
materialFormId: z.string(),
isMetric: z.boolean(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1001,9 +1001,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialFinish",
{
description: "get material finish",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1016,13 +1016,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialFinishes",
{
description: "get material finishes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1035,9 +1035,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialFinishList",
{
description: "get material finish list",
- inputSchema: {
+ inputSchema: z.object({
materialSubstanceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1050,9 +1050,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialForm",
{
description: "get material form",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1065,13 +1065,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialForms",
{
description: "get material forms",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1084,7 +1084,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialFormsList",
{
description: "get material forms list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1097,13 +1097,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialGrades",
{
description: "get material grades",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1116,9 +1116,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialGrade",
{
description: "get material grade",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1131,9 +1131,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialGradeList",
{
description: "get material grade list",
- inputSchema: {
+ inputSchema: z.object({
materialSubstanceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1146,9 +1146,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialSubstance",
{
description: "get material substance",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1161,13 +1161,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialSubstances",
{
description: "get material substances",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1180,7 +1180,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialSubstancesList",
{
description: "get material substances list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1193,9 +1193,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodMaterial",
{
description: "get method material",
- inputSchema: {
+ inputSchema: z.object({
materialId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1208,13 +1208,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodMaterials",
{
description: "get method materials",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1227,9 +1227,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodMaterialsByMakeMethod",
{
description: "get method materials by make method",
- inputSchema: {
+ inputSchema: z.object({
makeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1242,13 +1242,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodOperations",
{
description: "get method operations",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1261,9 +1261,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodOperationsByMakeMethodId",
{
description: "get method operations by make method id",
- inputSchema: {
+ inputSchema: z.object({
makeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1276,9 +1276,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodTree",
{
description: "get method tree",
- inputSchema: {
+ inputSchema: z.object({
makeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1291,9 +1291,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMethodTreeArray",
{
description: "get method tree array",
- inputSchema: {
+ inputSchema: z.object({
makeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1306,12 +1306,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getOpenJobMaterials",
{
description: "get open job materials",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1324,12 +1324,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getOpenProductionOrders",
{
description: "get open production orders",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1342,12 +1342,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getOpenPurchaseOrderLines",
{
description: "get open purchase order lines",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1360,12 +1360,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getOpenSalesOrderLines",
{
description: "get open sales order lines",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
itemId: z.string(),
locationId: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1378,9 +1378,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getPart",
{
description: "get part",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1393,14 +1393,14 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getParts",
{
description: "get parts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1413,7 +1413,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getPartsList",
{
description: "get parts list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1426,9 +1426,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getPartUsedIn",
{
description: "get part used in",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1441,10 +1441,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getPickMethod",
{
description: "get pick method",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1457,9 +1457,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getPickMethods",
{
description: "get pick methods",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1472,7 +1472,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getServices",
{
description: "get services",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -1481,7 +1481,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
group: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1494,9 +1494,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getService",
{
description: "get service",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1509,7 +1509,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getServicesList",
{
description: "get services list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1522,9 +1522,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getSupplierParts",
{
description: "get supplier parts",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1537,9 +1537,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getTool",
{
description: "get tool",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1552,14 +1552,14 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getTools",
{
description: "get tools",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1572,7 +1572,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getToolsList",
{
description: "get tools list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1585,9 +1585,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getUnitOfMeasure",
{
description: "get unit of measure",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1600,13 +1600,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getUnitOfMeasures",
{
description: "get unit of measures",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1619,7 +1619,7 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getUnitOfMeasuresList",
{
description: "get unit of measures list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1632,9 +1632,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateConfigurationParameterGroupOrder",
{
description: "update configuration parameter group order",
- inputSchema: {
+ inputSchema: z.object({
data: configurationParameterGroupOrderValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1647,11 +1647,11 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateDefaultRevision",
{
description: "update default revision",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1664,9 +1664,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateConfigurationParameterOrder",
{
description: "update configuration parameter order",
- inputSchema: {
+ inputSchema: z.object({
data: configurationParameterOrderValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1679,12 +1679,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateItemCost",
{
description: "update item cost",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
cost: z.object({
unitCost: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1697,12 +1697,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateMaterialOrder",
{
description: "update material order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1715,12 +1715,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateOperationOrder",
{
description: "update operation order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1733,12 +1733,12 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateRevision",
{
description: "update revision",
- inputSchema: {
+ inputSchema: z.object({
revision: z.object({
id: z.string(),
revision: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1751,9 +1751,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertConfigurationParameter",
{
description: "upsert configuration parameter",
- inputSchema: {
+ inputSchema: z.object({
configurationParameter: configurationParameterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1766,9 +1766,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertConfigurationParameterGroup",
{
description: "upsert configuration parameter group",
- inputSchema: {
+ inputSchema: z.object({
configurationParameterGroup: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1781,9 +1781,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertConfigurationRule",
{
description: "upsert configuration rule",
- inputSchema: {
+ inputSchema: z.object({
configurationRule: configurationRuleValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1796,9 +1796,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertConsumable",
{
description: "upsert consumable",
- inputSchema: {
+ inputSchema: z.object({
consumable: consumableValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1811,9 +1811,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertPart",
{
description: "upsert part",
- inputSchema: {
+ inputSchema: z.object({
part: partValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1826,9 +1826,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_updateItem",
{
description: "update item",
- inputSchema: {
+ inputSchema: z.object({
item: itemValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1841,9 +1841,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemCost",
{
description: "upsert item cost",
- inputSchema: {
+ inputSchema: z.object({
itemCost: itemCostValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1856,9 +1856,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertPickMethod",
{
description: "upsert pick method",
- inputSchema: {
+ inputSchema: z.object({
pickMethod: pickMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1871,9 +1871,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemManufacturing",
{
description: "upsert item manufacturing",
- inputSchema: {
+ inputSchema: z.object({
partManufacturing: itemManufacturingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1886,9 +1886,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemPlanning",
{
description: "upsert item planning",
- inputSchema: {
+ inputSchema: z.object({
partPlanning: itemPlanningValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1901,9 +1901,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemPurchasing",
{
description: "upsert item purchasing",
- inputSchema: {
+ inputSchema: z.object({
itemPurchasing: itemPurchasingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1916,9 +1916,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemPostingGroup",
{
description: "upsert item posting group",
- inputSchema: {
+ inputSchema: z.object({
itemPostingGroup: itemPostingGroupValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1931,9 +1931,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertSupplierPart",
{
description: "upsert supplier part",
- inputSchema: {
+ inputSchema: z.object({
supplierPart: supplierPartValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1946,9 +1946,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemCustomerPart",
{
description: "upsert item customer part",
- inputSchema: {
+ inputSchema: z.object({
customerPart: customerPartValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1961,9 +1961,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertItemUnitSalePrice",
{
description: "upsert item unit sale price",
- inputSchema: {
+ inputSchema: z.object({
itemUnitSalePrice: itemUnitSalePriceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1976,9 +1976,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMakeMethodVersion",
{
description: "upsert make method version",
- inputSchema: {
+ inputSchema: z.object({
makeMethodVersion: makeMethodVersionValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1991,9 +1991,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMethodMaterial",
{
description: "upsert method material",
- inputSchema: {
+ inputSchema: z.object({
methodMaterial: methodMaterialValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2006,9 +2006,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMethodOperation",
{
description: "upsert method operation",
- inputSchema: {
+ inputSchema: z.object({
methodOperation: methodOperationValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2021,9 +2021,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMethodOperationStep",
{
description: "upsert method operation step",
- inputSchema: {
+ inputSchema: z.object({
methodOperationStep: operationStepValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2036,9 +2036,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMethodOperationParameter",
{
description: "upsert method operation parameter",
- inputSchema: {
+ inputSchema: z.object({
methodOperationParameter: operationParameterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2051,9 +2051,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMethodOperationTool",
{
description: "upsert method operation tool",
- inputSchema: {
+ inputSchema: z.object({
methodOperationTool: operationToolValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2066,9 +2066,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterial",
{
description: "upsert material",
- inputSchema: {
+ inputSchema: z.object({
material: materialValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2081,9 +2081,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialDimension",
{
description: "upsert material dimension",
- inputSchema: {
+ inputSchema: z.object({
materialDimension: materialDimensionValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2096,9 +2096,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialFinish",
{
description: "upsert material finish",
- inputSchema: {
+ inputSchema: z.object({
materialFinish: materialFinishValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2111,9 +2111,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialForm",
{
description: "upsert material form",
- inputSchema: {
+ inputSchema: z.object({
materialForm: materialFormValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2126,9 +2126,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialGrade",
{
description: "upsert material grade",
- inputSchema: {
+ inputSchema: z.object({
materialGrade: materialGradeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2141,9 +2141,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_deleteMaterialType",
{
description: "delete material type",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2156,13 +2156,13 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialTypes",
{
description: "get material types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2175,9 +2175,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialType",
{
description: "get material type",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2190,10 +2190,10 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getMaterialTypeList",
{
description: "get material type list",
- inputSchema: {
+ inputSchema: z.object({
materialSubstanceId: z.string(),
materialFormId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2206,9 +2206,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialType",
{
description: "upsert material type",
- inputSchema: {
+ inputSchema: z.object({
materialType: materialTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2221,9 +2221,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertMaterialSubstance",
{
description: "upsert material substance",
- inputSchema: {
+ inputSchema: z.object({
materialSubstance: materialSubstanceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2236,9 +2236,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertService",
{
description: "upsert service",
- inputSchema: {
+ inputSchema: z.object({
service: serviceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2251,9 +2251,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertUnitOfMeasure",
{
description: "upsert unit of measure",
- inputSchema: {
+ inputSchema: z.object({
unitOfMeasure: unitOfMeasureValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2266,9 +2266,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_upsertTool",
{
description: "upsert tool",
- inputSchema: {
+ inputSchema: z.object({
tool: toolValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2281,9 +2281,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getSupplierPriceBreaksForItems",
{
description: "get supplier price breaks for items",
- inputSchema: {
+ inputSchema: z.object({
itemIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2296,11 +2296,11 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_lookupBuyPrice",
{
description: "lookup buy price",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
qty: z.number(),
fallbackCost: z.number(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2313,9 +2313,9 @@ export const registerItemsTools: RegisterTools = (server, ctx) => {
"items_getSupplierPartPriceBreaks",
{
description: "get supplier part price breaks",
- inputSchema: {
+ inputSchema: z.object({
supplierPartId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/people.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/people.ts
index 2dfe7c9f08..90c36229c3 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/people.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/people.ts
@@ -67,9 +67,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteAttribute",
{
description: "delete attribute",
- inputSchema: {
+ inputSchema: z.object({
attributeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -82,9 +82,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteAttributeCategory",
{
description: "delete attribute category",
- inputSchema: {
+ inputSchema: z.object({
attributeCategoryId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -97,9 +97,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteDepartment",
{
description: "delete department",
- inputSchema: {
+ inputSchema: z.object({
departmentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -112,9 +112,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteHoliday",
{
description: "delete holiday",
- inputSchema: {
+ inputSchema: z.object({
holidayId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -127,9 +127,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteShift",
{
description: "delete shift",
- inputSchema: {
+ inputSchema: z.object({
shiftId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -142,9 +142,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getAttribute",
{
description: "get attribute",
- inputSchema: {
+ inputSchema: z.object({
attributeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -157,12 +157,12 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getAttributeCategories",
{
description: "get attribute categories",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -175,9 +175,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getAttributeCategory",
{
description: "get attribute category",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -190,7 +190,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getAttributeDataTypes",
{
description: "get attribute data types",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -203,9 +203,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getDepartment",
{
description: "get department",
- inputSchema: {
+ inputSchema: z.object({
departmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -218,13 +218,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getDepartments",
{
description: "get departments",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -237,7 +237,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getDepartmentsList",
{
description: "get departments list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -250,9 +250,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getEmployeeJob",
{
description: "get employee job",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -265,9 +265,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getEmployeeSummary",
{
description: "get employee summary",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -280,9 +280,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getHoliday",
{
description: "get holiday",
- inputSchema: {
+ inputSchema: z.object({
holidayId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -295,13 +295,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getHolidays",
{
description: "get holidays",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -314,13 +314,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getPeople",
{
description: "get people",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -333,13 +333,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getContacts",
{
description: "get contacts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -352,9 +352,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getShift",
{
description: "get shift",
- inputSchema: {
+ inputSchema: z.object({
shiftId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -367,13 +367,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getShifts",
{
description: "get shifts",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -386,9 +386,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getShiftsList",
{
description: "get shifts list",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string().nullable(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -401,7 +401,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_insertAttribute",
{
description: "insert attribute",
- inputSchema: {
+ inputSchema: z.object({
attribute: z.object({
name: z.string(),
attributeDataTypeId: z.number(),
@@ -409,7 +409,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
listOptions: z.array(z.string()).optional(),
canSelfManage: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -422,13 +422,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_insertAttributeCategory",
{
description: "insert attribute category",
- inputSchema: {
+ inputSchema: z.object({
attributeCategory: z.object({
name: z.string(),
emoji: z.string().optional(),
public: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -441,12 +441,12 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_insertEmployeeJob",
{
description: "insert employee job",
- inputSchema: {
+ inputSchema: z.object({
job: z.object({
id: z.string(),
locationId: z.string().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -459,14 +459,14 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_updateAttribute",
{
description: "update attribute",
- inputSchema: {
+ inputSchema: z.object({
attribute: z.object({
id: z.string().optional(),
name: z.string(),
listOptions: z.array(z.string()).optional(),
canSelfManage: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -479,14 +479,14 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_updateAttributeCategory",
{
description: "update attribute category",
- inputSchema: {
+ inputSchema: z.object({
attributeCategory: z.object({
id: z.string(),
name: z.string(),
emoji: z.string().optional(),
public: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -499,12 +499,12 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_updateAttributeSortOrder",
{
description: "update attribute sort order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -517,10 +517,10 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_updateEmployeeJob",
{
description: "update employee job",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
employeeJob: employeeJobValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -533,9 +533,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_upsertDepartment",
{
description: "upsert department",
- inputSchema: {
+ inputSchema: z.object({
department: departmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -548,9 +548,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_upsertHoliday",
{
description: "upsert holiday",
- inputSchema: {
+ inputSchema: z.object({
holiday: holidayValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -563,9 +563,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_upsertShift",
{
description: "upsert shift",
- inputSchema: {
+ inputSchema: z.object({
shift: shiftValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -578,11 +578,11 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_clockIn",
{
description: "clock in",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
employeeId: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -595,13 +595,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_clockOut",
{
description: "clock out",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
employeeId: z.string(),
clockOut: z.string().optional(),
note: z.string().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -614,14 +614,14 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_createTimeCardEntry",
{
description: "create time card entry",
- inputSchema: {
+ inputSchema: z.object({
entry: z.object({
employeeId: z.string(),
clockIn: z.string(),
clockOut: z.string().nullable().optional(),
note: z.string().nullable().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -634,9 +634,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_deleteTimeCardEntry",
{
description: "delete time card entry",
- inputSchema: {
+ inputSchema: z.object({
entryId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -649,7 +649,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getClockedInEmployees",
{
description: "get clocked in employees",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -662,9 +662,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getOpenClockEntry",
{
description: "get open clock entry",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -677,7 +677,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getRecentTimecards",
{
description: "get recent timecards",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -690,7 +690,7 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getScheduledEmployeesToday",
{
description: "get scheduled employees today",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -703,9 +703,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getTimeCardEntry",
{
description: "get time card entry",
- inputSchema: {
+ inputSchema: z.object({
entryId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -718,13 +718,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getTimeCardEntries",
{
description: "get time card entries",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
employeeId: z.string(),
from: z.string().optional(),
to: z.string().optional()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -737,13 +737,13 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getTimecardEntries",
{
description: "get timecard entries",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -756,9 +756,9 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_getWeeklyHoursForEmployees",
{
description: "get weekly hours for employees",
- inputSchema: {
+ inputSchema: z.object({
employeeIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -771,14 +771,14 @@ export const registerPeopleTools: RegisterTools = (server, ctx) => {
"people_updateTimeCardEntry",
{
description: "update time card entry",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
entryId: z.string(),
clockIn: z.string().optional(),
clockOut: z.string().nullable().optional(),
note: z.string().nullable().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/production.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/production.ts
index be0f1620a6..3706ce656c 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/production.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/production.ts
@@ -170,11 +170,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_convertSalesOrderLinesToJobs",
{
description: "convert sales order lines to jobs",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
orderId: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -187,14 +187,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_calculateJobPriority",
{
description: "calculate job priority",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
jobId: z.string().optional(),
dueDate: z.string().nullable(),
deadlineType: z.any(),
locationId: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -207,13 +207,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteDemandForecasts",
{
description: "delete demand forecasts",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
itemId: z.string(),
locationId: z.string(),
futurePeriodIds: z.array(z.string())
}),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -226,13 +226,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteDemandProjections",
{
description: "delete demand projections",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
itemId: z.string(),
locationId: z.string(),
futurePeriodIds: z.array(z.string())
}),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -245,9 +245,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJob",
{
description: "delete job",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -260,9 +260,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJobMaterial",
{
description: "delete job material",
- inputSchema: {
+ inputSchema: z.object({
jobMaterialId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -275,9 +275,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJobOperation",
{
description: "delete job operation",
- inputSchema: {
+ inputSchema: z.object({
jobOperationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -290,9 +290,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJobOperationStep",
{
description: "delete job operation step",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -305,9 +305,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJobOperationParameter",
{
description: "delete job operation parameter",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -320,9 +320,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteJobOperationTool",
{
description: "delete job operation tool",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -335,9 +335,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteProcedure",
{
description: "delete procedure",
- inputSchema: {
+ inputSchema: z.object({
procedureId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -350,9 +350,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteProcedureStep",
{
description: "delete procedure step",
- inputSchema: {
+ inputSchema: z.object({
procedureStepId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -365,9 +365,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteProcedureParameter",
{
description: "delete procedure parameter",
- inputSchema: {
+ inputSchema: z.object({
procedureParameterId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -380,9 +380,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteProductionEvent",
{
description: "delete production event",
- inputSchema: {
+ inputSchema: z.object({
productionEventId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -395,9 +395,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteProductionQuantity",
{
description: "delete production quantity",
- inputSchema: {
+ inputSchema: z.object({
productionQuantityId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -410,9 +410,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getActiveJobOperationByJobId",
{
description: "get active job operation by job id",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -425,10 +425,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getActiveJobOperationsByLocation",
{
description: "get active job operations by location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
workCenterIds: z.array(z.string()).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -441,11 +441,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobsByDateRange",
{
description: "get jobs by date range",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
startDate: z.string(),
endDate: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -458,9 +458,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getUnscheduledJobs",
{
description: "get unscheduled jobs",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -473,7 +473,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getActiveProductionEvents",
{
description: "get active production events",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -486,9 +486,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteScrapReason",
{
description: "delete scrap reason",
- inputSchema: {
+ inputSchema: z.object({
scrapReasonId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -501,9 +501,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteFailureMode",
{
description: "delete failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureModeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -516,9 +516,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceDispatch",
{
description: "delete maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -531,9 +531,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceDispatchComment",
{
description: "delete maintenance dispatch comment",
- inputSchema: {
+ inputSchema: z.object({
commentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -546,9 +546,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceDispatchEvent",
{
description: "delete maintenance dispatch event",
- inputSchema: {
+ inputSchema: z.object({
eventId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -561,9 +561,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceDispatchItem",
{
description: "delete maintenance dispatch item",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -576,9 +576,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceDispatchWorkCenter",
{
description: "delete maintenance dispatch work center",
- inputSchema: {
+ inputSchema: z.object({
workCenterId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -591,9 +591,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceSchedule",
{
description: "delete maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -606,9 +606,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_deleteMaintenanceScheduleItem",
{
description: "delete maintenance schedule item",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -621,13 +621,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getDemandForecasts",
{
description: "get demand forecasts",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
itemId: z.string(),
locationId: z.string(),
periodIds: z.array(z.string())
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -640,13 +640,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getDemandProjections",
{
description: "get demand projections",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
itemId: z.string(),
locationId: z.string(),
periodIds: z.array(z.string())
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -659,14 +659,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobDocuments",
{
description: "get job documents",
- inputSchema: {
+ inputSchema: z.object({
job: z.object({
id: z.string().nullable(),
salesOrderLineId: z.string().nullable().optional(),
quoteLineId: z.string().nullable().optional(),
itemId: z.string().nullable().optional()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -679,10 +679,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobDocumentsWithItemId",
{
description: "get job documents with item id",
- inputSchema: {
+ inputSchema: z.object({
job: z.any(),
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -695,9 +695,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJob",
{
description: "get job",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -710,9 +710,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobByOperationId",
{
description: "get job by operation id",
- inputSchema: {
+ inputSchema: z.object({
operationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -725,9 +725,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobPurchaseOrderLines",
{
description: "get job purchase order lines",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -740,12 +740,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobs",
{
description: "get jobs",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -758,9 +758,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobsBySalesOrderLine",
{
description: "get jobs by sales order line",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -773,7 +773,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobsList",
{
description: "get jobs list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -786,9 +786,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMakeMethodById",
{
description: "get job make method by id",
- inputSchema: {
+ inputSchema: z.object({
jobMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -801,9 +801,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getRootMakeMethod",
{
description: "get root make method",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -816,14 +816,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMaterialsWithQuantityOnHand",
{
description: "get job materials with quantity on hand",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -836,9 +836,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMethodTree",
{
description: "get job method tree",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -851,9 +851,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMethodTreeArray",
{
description: "get job method tree array",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -866,9 +866,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMaterial",
{
description: "get job material",
- inputSchema: {
+ inputSchema: z.object({
materialId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -881,9 +881,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobMaterialsByMethodId",
{
description: "get job materials by method id",
- inputSchema: {
+ inputSchema: z.object({
jobMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -896,9 +896,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperation",
{
description: "get job operation",
- inputSchema: {
+ inputSchema: z.object({
jobOperationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -911,13 +911,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperations",
{
description: "get job operations",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -930,9 +930,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperationsAssignedToEmployee",
{
description: "get job operations assigned to employee",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -945,9 +945,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperationAttachments",
{
description: "get job operation attachments",
- inputSchema: {
+ inputSchema: z.object({
jobOperationIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -960,9 +960,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperationsList",
{
description: "get job operations list",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -975,9 +975,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperationsByMethodId",
{
description: "get job operations by method id",
- inputSchema: {
+ inputSchema: z.object({
jobMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -990,14 +990,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getJobOperationStepRecords",
{
description: "get job operation step records",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1010,9 +1010,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getOutsideOperationsByJobId",
{
description: "get outside operations by job id",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1025,9 +1025,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProcedure",
{
description: "get procedure",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1040,9 +1040,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProcedureSteps",
{
description: "get procedure steps",
- inputSchema: {
+ inputSchema: z.object({
procedureId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1055,9 +1055,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProcedureParameters",
{
description: "get procedure parameters",
- inputSchema: {
+ inputSchema: z.object({
procedureId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1070,12 +1070,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProcedureVersions",
{
description: "get procedure versions",
- inputSchema: {
+ inputSchema: z.object({
procedure: z.object({
name: z.string(),
version: z.number()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1088,12 +1088,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProcedures",
{
description: "get procedures",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1106,7 +1106,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProceduresList",
{
description: "get procedures list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1119,9 +1119,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionEvent",
{
description: "get production event",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1134,13 +1134,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionEvents",
{
description: "get production events",
- inputSchema: {
+ inputSchema: z.object({
jobOperationIds: z.array(z.string()),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1153,11 +1153,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionEventsPage",
{
description: "get production events page",
- inputSchema: {
+ inputSchema: z.object({
jobOperationId: z.string(),
sortDescending: z.boolean().optional(),
page: z.number().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1170,9 +1170,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionEventsByOperations",
{
description: "get production events by operations",
- inputSchema: {
+ inputSchema: z.object({
jobOperationIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1185,7 +1185,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionPlanning",
{
description: "get production planning",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
periods: z.array(z.string()),
args: z.object({
@@ -1193,7 +1193,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1206,7 +1206,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionProjections",
{
description: "get production projections",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
periods: z.array(z.string()),
args: z.object({
@@ -1214,7 +1214,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1227,9 +1227,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionQuantity",
{
description: "get production quantity",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1242,13 +1242,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionQuantities",
{
description: "get production quantities",
- inputSchema: {
+ inputSchema: z.object({
jobOperationIds: z.array(z.string()),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1261,9 +1261,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getProductionDataByOperations",
{
description: "get production data by operations",
- inputSchema: {
+ inputSchema: z.object({
jobOperationIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1276,7 +1276,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getScrapReasonsList",
{
description: "get scrap reasons list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1289,9 +1289,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getScrapReason",
{
description: "get scrap reason",
- inputSchema: {
+ inputSchema: z.object({
scrapReasonId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1304,13 +1304,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getScrapReasons",
{
description: "get scrap reasons",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1323,9 +1323,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getFailureMode",
{
description: "get failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureModeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1338,13 +1338,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getFailureModes",
{
description: "get failure modes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1357,7 +1357,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getFailureModesList",
{
description: "get failure modes list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1370,9 +1370,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatch",
{
description: "get maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1385,14 +1385,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatches",
{
description: "get maintenance dispatches",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
status: z.string().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1405,9 +1405,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatchComments",
{
description: "get maintenance dispatch comments",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1420,9 +1420,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatchEvents",
{
description: "get maintenance dispatch events",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1435,9 +1435,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatchItems",
{
description: "get maintenance dispatch items",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1450,9 +1450,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceDispatchWorkCenters",
{
description: "get maintenance dispatch work centers",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1465,9 +1465,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceSchedule",
{
description: "get maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1480,14 +1480,14 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceSchedules",
{
description: "get maintenance schedules",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
active: z.boolean().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1500,9 +1500,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getMaintenanceScheduleItems",
{
description: "get maintenance schedule items",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1515,9 +1515,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getTrackedEntityByJobId",
{
description: "get tracked entity by job id",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1530,9 +1530,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_getTrackedEntitiesByJobId",
{
description: "get tracked entities by job id",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1545,11 +1545,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_recalculateJobOperationDependencies",
{
description: "recalculate job operation dependencies",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
jobId: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1562,11 +1562,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_recalculateJobRequirements",
{
description: "recalculate job requirements",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1579,11 +1579,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_recalculateJobMakeMethodRequirements",
{
description: "recalculate job make method requirements",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1596,12 +1596,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_runMRP",
{
description: "run m r p",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
type: z.any(),
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1614,10 +1614,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobBatchNumber",
{
description: "update job batch number",
- inputSchema: {
+ inputSchema: z.object({
trackedEntityId: z.string(),
value: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1630,13 +1630,13 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobStatus",
{
description: "update job status",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
id: z.string(),
status: z.any(),
assignee: z.string().nullable().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1649,12 +1649,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobMaterialOrder",
{
description: "update job material order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1667,12 +1667,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobOperationOrder",
{
description: "update job operation order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1685,12 +1685,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobOperationStepOrder",
{
description: "update job operation step order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1703,12 +1703,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateKanbanJob",
{
description: "update kanban job",
- inputSchema: {
+ inputSchema: z.object({
params: z.object({
id: z.string(),
jobId: z.string().nullable()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1721,12 +1721,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateQuoteOperationStepOrder",
{
description: "update quote operation step order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1739,12 +1739,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateMethodOperationStepOrder",
{
description: "update method operation step order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1757,10 +1757,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobOperationStatus",
{
description: "update job operation status",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
status: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1773,10 +1773,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateJobOperationDueDate",
{
description: "update job operation due date",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
dueDate: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1789,12 +1789,12 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateProcedureStepOrder",
{
description: "update procedure step order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1807,9 +1807,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertProductionEvent",
{
description: "upsert production event",
- inputSchema: {
+ inputSchema: z.object({
productionEvent: productionEventValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1822,9 +1822,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_updateProductionQuantity",
{
description: "update production quantity",
- inputSchema: {
+ inputSchema: z.object({
productionQuantity: productionQuantityValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1837,9 +1837,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertProductionQuantity",
{
description: "upsert production quantity",
- inputSchema: {
+ inputSchema: z.object({
productionQuantity: productionQuantityValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1852,10 +1852,10 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJob",
{
description: "upsert job",
- inputSchema: {
+ inputSchema: z.object({
job: jobValidator,
status: z.any().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1868,9 +1868,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobMaterial",
{
description: "upsert job material",
- inputSchema: {
+ inputSchema: z.object({
jobMaterial: jobMaterialValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1883,9 +1883,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobOperation",
{
description: "upsert job operation",
- inputSchema: {
+ inputSchema: z.object({
jobOperation: jobOperationValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1898,9 +1898,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobOperationStep",
{
description: "upsert job operation step",
- inputSchema: {
+ inputSchema: z.object({
jobOperationStep: operationStepValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1913,9 +1913,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobOperationParameter",
{
description: "upsert job operation parameter",
- inputSchema: {
+ inputSchema: z.object({
jobOperationParameter: operationParameterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1928,9 +1928,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobOperationTool",
{
description: "upsert job operation tool",
- inputSchema: {
+ inputSchema: z.object({
jobOperationTool: operationToolValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1943,7 +1943,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobMethod",
{
description: "upsert job method",
- inputSchema: {
+ inputSchema: z.object({
type: z.string(),
jobMethod: z.object({
sourceId: z.string(),
@@ -1957,7 +1957,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1970,7 +1970,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertJobMaterialMakeMethod",
{
description: "upsert job material make method",
- inputSchema: {
+ inputSchema: z.object({
jobMaterial: z.object({
sourceId: z.string(),
targetId: z.string(),
@@ -1983,7 +1983,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1996,7 +1996,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMakeMethodFromJob",
{
description: "upsert make method from job",
- inputSchema: {
+ inputSchema: z.object({
jobMethod: z.object({
sourceId: z.string(),
targetId: z.string(),
@@ -2008,7 +2008,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2021,7 +2021,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMakeMethodFromJobMethod",
{
description: "upsert make method from job method",
- inputSchema: {
+ inputSchema: z.object({
jobMethod: z.object({
sourceId: z.string(),
targetId: z.string(),
@@ -2033,7 +2033,7 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2046,9 +2046,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertProcedure",
{
description: "upsert procedure",
- inputSchema: {
+ inputSchema: z.object({
procedure: procedureValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2061,9 +2061,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertProcedureStep",
{
description: "upsert procedure step",
- inputSchema: {
+ inputSchema: z.object({
procedureStep: procedureStepValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2076,9 +2076,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertProcedureParameter",
{
description: "upsert procedure parameter",
- inputSchema: {
+ inputSchema: z.object({
procedureParameter: procedureParameterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2091,9 +2091,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertScrapReason",
{
description: "upsert scrap reason",
- inputSchema: {
+ inputSchema: z.object({
scrapReason: scrapReasonValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2106,9 +2106,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertFailureMode",
{
description: "upsert failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureMode: failureModeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2121,9 +2121,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceDispatch",
{
description: "upsert maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatch: maintenanceDispatchValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2136,9 +2136,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceDispatchComment",
{
description: "upsert maintenance dispatch comment",
- inputSchema: {
+ inputSchema: z.object({
comment: maintenanceDispatchCommentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2151,9 +2151,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceDispatchEvent",
{
description: "upsert maintenance dispatch event",
- inputSchema: {
+ inputSchema: z.object({
event: maintenanceDispatchEventValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2166,9 +2166,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceDispatchItem",
{
description: "upsert maintenance dispatch item",
- inputSchema: {
+ inputSchema: z.object({
item: maintenanceDispatchItemValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2181,9 +2181,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceDispatchWorkCenter",
{
description: "upsert maintenance dispatch work center",
- inputSchema: {
+ inputSchema: z.object({
workCenter: maintenanceDispatchWorkCenterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2196,9 +2196,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceSchedule",
{
description: "upsert maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
schedule: maintenanceScheduleValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2211,9 +2211,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertMaintenanceScheduleItem",
{
description: "upsert maintenance schedule item",
- inputSchema: {
+ inputSchema: z.object({
item: maintenanceScheduleItemValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2226,9 +2226,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertDemandForecasts",
{
description: "upsert demand forecasts",
- inputSchema: {
+ inputSchema: z.object({
forecasts: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2241,9 +2241,9 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_upsertDemandProjections",
{
description: "upsert demand projections",
- inputSchema: {
+ inputSchema: z.object({
forecasts: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2256,11 +2256,11 @@ export const registerProductionTools: RegisterTools = (server, ctx) => {
"production_triggerJobSchedule",
{
description: "trigger job schedule",
- inputSchema: {
+ inputSchema: z.object({
jobId: z.string(),
mode: z.string().optional(),
direction: z.string().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/purchasing.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/purchasing.ts
index 6419e5f893..016cec8198 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/purchasing.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/purchasing.ts
@@ -129,9 +129,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_closePurchaseOrder",
{
description: "close purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -144,9 +144,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_convertSupplierQuoteToOrder",
{
description: "convert supplier quote to order",
- inputSchema: {
+ inputSchema: z.object({
payload: selectedLinesValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -159,9 +159,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deletePurchaseOrder",
{
description: "delete purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -174,9 +174,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deletePurchaseOrderLine",
{
description: "delete purchase order line",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -189,9 +189,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplier",
{
description: "delete supplier",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -204,10 +204,10 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierContact",
{
description: "delete supplier contact",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
supplierContactId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -220,10 +220,10 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierLocation",
{
description: "delete supplier location",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
supplierLocationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -236,9 +236,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierProcess",
{
description: "delete supplier process",
- inputSchema: {
+ inputSchema: z.object({
supplierProcessId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -251,9 +251,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierQuote",
{
description: "delete supplier quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -266,9 +266,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierQuoteLine",
{
description: "delete supplier quote line",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -281,9 +281,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deleteSupplierType",
{
description: "delete supplier type",
- inputSchema: {
+ inputSchema: z.object({
supplierTypeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -296,9 +296,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrder",
{
description: "get purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -311,9 +311,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_finalizeSupplierQuote",
{
description: "finalize supplier quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -326,7 +326,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrders",
{
description: "get purchase orders",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -334,7 +334,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
status: z.string().nullable(),
supplierId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -347,9 +347,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderDelivery",
{
description: "get purchase order delivery",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -362,9 +362,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderLocations",
{
description: "get purchase order locations",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -377,9 +377,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderPayment",
{
description: "get purchase order payment",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -392,9 +392,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderLines",
{
description: "get purchase order lines",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -407,9 +407,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderLine",
{
description: "get purchase order line",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -422,7 +422,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchaseOrderSuppliers",
{
description: "get purchase order suppliers",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -435,7 +435,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingDocumentsAssignedToMe",
{
description: "get purchasing documents assigned to me",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -448,7 +448,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingPlanning",
{
description: "get purchasing planning",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
periods: z.array(z.string()),
args: z.object({
@@ -456,7 +456,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -469,7 +469,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingTerms",
{
description: "get purchasing terms",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -482,9 +482,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplier",
{
description: "get supplier",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -497,10 +497,10 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierApprovalContext",
{
description: "get supplier approval context",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
status: z.string().nullable(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -513,9 +513,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierContact",
{
description: "get supplier contact",
- inputSchema: {
+ inputSchema: z.object({
supplierContactId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -528,9 +528,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierContacts",
{
description: "get supplier contacts",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -543,9 +543,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierInteraction",
{
description: "get supplier interaction",
- inputSchema: {
+ inputSchema: z.object({
opportunityId: z.string().nullable(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -558,9 +558,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierInteractionDocuments",
{
description: "get supplier interaction documents",
- inputSchema: {
+ inputSchema: z.object({
interactionId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -573,9 +573,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierInteractionLineDocuments",
{
description: "get supplier interaction line documents",
- inputSchema: {
+ inputSchema: z.object({
lineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -588,9 +588,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierLocations",
{
description: "get supplier locations",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -603,9 +603,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierLocation",
{
description: "get supplier location",
- inputSchema: {
+ inputSchema: z.object({
supplierContactId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -618,9 +618,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierPayment",
{
description: "get supplier payment",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -633,9 +633,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierProcessById",
{
description: "get supplier process by id",
- inputSchema: {
+ inputSchema: z.object({
supplierProcessId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -648,9 +648,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierProcessesByProcess",
{
description: "get supplier processes by process",
- inputSchema: {
+ inputSchema: z.object({
processId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -663,9 +663,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierProcessesBySupplier",
{
description: "get supplier processes by supplier",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -678,9 +678,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuote",
{
description: "get supplier quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -693,9 +693,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteByInteractionId",
{
description: "get supplier quote by interaction id",
- inputSchema: {
+ inputSchema: z.object({
interactionId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -708,9 +708,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteByExternalLinkId",
{
description: "get supplier quote by external link id",
- inputSchema: {
+ inputSchema: z.object({
externalLinkId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -723,13 +723,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuotes",
{
description: "get supplier quotes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -742,9 +742,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteLine",
{
description: "get supplier quote line",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -757,9 +757,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteLines",
{
description: "get supplier quote lines",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -772,9 +772,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteLinePrices",
{
description: "get supplier quote line prices",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -787,9 +787,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuoteLinePricesByQuoteId",
{
description: "get supplier quote line prices by quote id",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -802,7 +802,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuotesList",
{
description: "get supplier quotes list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -815,9 +815,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierShipping",
{
description: "get supplier shipping",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -830,7 +830,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSuppliers",
{
description: "get suppliers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -838,7 +838,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
type: z.string().nullable(),
status: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -851,7 +851,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSuppliersList",
{
description: "get suppliers list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -864,9 +864,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierType",
{
description: "get supplier type",
- inputSchema: {
+ inputSchema: z.object({
supplierTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -879,13 +879,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierTypes",
{
description: "get supplier types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -898,7 +898,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierTypesList",
{
description: "get supplier types list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -911,9 +911,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_insertSupplier",
{
description: "insert supplier",
- inputSchema: {
+ inputSchema: z.object({
supplier: supplierValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -926,9 +926,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_insertSupplierContact",
{
description: "insert supplier contact",
- inputSchema: {
+ inputSchema: z.object({
supplierContact: supplierContactValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -941,9 +941,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_insertSupplierInteraction",
{
description: "insert supplier interaction",
- inputSchema: {
+ inputSchema: z.object({
supplierId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -956,7 +956,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_insertSupplierLocation",
{
description: "insert supplier location",
- inputSchema: {
+ inputSchema: z.object({
supplierLocation: z.object({
supplierId: z.string(),
name: z.string(),
@@ -969,7 +969,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
countryCode: z.string().optional(),
customFields: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -982,9 +982,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_finalizePurchaseOrder",
{
description: "finalize purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -997,9 +997,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_sendSupplierQuote",
{
description: "send supplier quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1012,12 +1012,12 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updatePurchaseOrder",
{
description: "update purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrder: z.object({
id: z.string(),
status: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1030,12 +1030,12 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updatePurchaseOrderExchangeRate",
{
description: "update purchase order exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1048,12 +1048,12 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updatePurchaseOrderFavorite",
{
description: "update purchase order favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1066,13 +1066,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updatePurchaseOrderStatus",
{
description: "update purchase order status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1085,9 +1085,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierAccounting",
{
description: "update supplier accounting",
- inputSchema: {
+ inputSchema: z.object({
supplierAccounting: supplierAccountingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1100,9 +1100,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierContact",
{
description: "update supplier contact",
- inputSchema: {
+ inputSchema: z.object({
supplierContact: supplierContactValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1115,7 +1115,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierLocation",
{
description: "update supplier location",
- inputSchema: {
+ inputSchema: z.object({
supplierLocation: z.object({
addressId: z.string(),
name: z.string(),
@@ -1128,7 +1128,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
postalCode: z.string().optional(),
customFields: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1141,9 +1141,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierPayment",
{
description: "update supplier payment",
- inputSchema: {
+ inputSchema: z.object({
supplierPayment: supplierPaymentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1156,12 +1156,12 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierQuoteExchangeRate",
{
description: "update supplier quote exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1174,12 +1174,12 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierQuoteFavorite",
{
description: "update supplier quote favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1192,13 +1192,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierQuoteStatus",
{
description: "update supplier quote status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1211,9 +1211,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updateSupplierShipping",
{
description: "update supplier shipping",
- inputSchema: {
+ inputSchema: z.object({
supplierShipping: supplierShippingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1226,10 +1226,10 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchaseOrder",
{
description: "upsert purchase order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrder: purchaseOrderValidator,
receiptRequestedDate: z.string().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1242,9 +1242,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchaseOrderDelivery",
{
description: "upsert purchase order delivery",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderDelivery: purchaseOrderDeliveryValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1257,9 +1257,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchaseOrderLine",
{
description: "upsert purchase order line",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderLine: purchaseOrderLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1272,9 +1272,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchaseOrderPayment",
{
description: "upsert purchase order payment",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderPayment: purchaseOrderPaymentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1287,9 +1287,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertSupplier",
{
description: "upsert supplier",
- inputSchema: {
+ inputSchema: z.object({
supplier: supplierValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1302,9 +1302,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertSupplierProcess",
{
description: "upsert supplier process",
- inputSchema: {
+ inputSchema: z.object({
supplierProcess: supplierProcessValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1317,9 +1317,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertSupplierQuote",
{
description: "upsert supplier quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuote: supplierQuoteValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1332,9 +1332,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertSupplierQuoteLine",
{
description: "upsert supplier quote line",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteLine: supplierQuoteLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1347,9 +1347,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertSupplierType",
{
description: "upsert supplier type",
- inputSchema: {
+ inputSchema: z.object({
supplierType: supplierTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1362,9 +1362,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deletePurchasingRFQ",
{
description: "delete purchasing r f q",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1377,9 +1377,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_deletePurchasingRFQLine",
{
description: "delete purchasing r f q line",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1392,9 +1392,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQ",
{
description: "get purchasing r f q",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1407,13 +1407,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQs",
{
description: "get purchasing r f qs",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1426,9 +1426,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQLine",
{
description: "get purchasing r f q line",
- inputSchema: {
+ inputSchema: z.object({
lineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1441,9 +1441,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQLines",
{
description: "get purchasing r f q lines",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1456,9 +1456,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQSuppliers",
{
description: "get purchasing r f q suppliers",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1471,7 +1471,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchasingRFQ",
{
description: "upsert purchasing r f q",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfq: z.object({
id: z.string().optional(),
rfqId: z.string(),
@@ -1482,7 +1482,7 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
status: z.any().optional(),
customFields: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1495,9 +1495,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchasingRFQLine",
{
description: "upsert purchasing r f q line",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqLine: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1510,10 +1510,10 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_upsertPurchasingRFQSuppliers",
{
description: "upsert purchasing r f q suppliers",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
supplierIds: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1526,13 +1526,13 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_updatePurchasingRFQStatus",
{
description: "update purchasing r f q status",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
status: z.any(),
assignee: z.string().nullable().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1545,9 +1545,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getLinkedSupplierQuotes",
{
description: "get linked supplier quotes",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1560,9 +1560,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getLinkedPurchasingRfqs",
{
description: "get linked purchasing rfqs",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1575,9 +1575,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getLinkedPurchasingRfqsForInteraction",
{
description: "get linked purchasing rfqs for interaction",
- inputSchema: {
+ inputSchema: z.object({
supplierInteractionId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1590,9 +1590,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSiblingQuotesForQuote",
{
description: "get sibling quotes for quote",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1605,9 +1605,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getLinkedPurchasingRfqsForOrder",
{
description: "get linked purchasing rfqs for order",
- inputSchema: {
+ inputSchema: z.object({
purchaseOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1620,9 +1620,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getSupplierQuotesForComparison",
{
description: "get supplier quotes for comparison",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1635,9 +1635,9 @@ export const registerPurchasingTools: RegisterTools = (server, ctx) => {
"purchasing_getPurchasingRFQSuppliersWithLinks",
{
description: "get purchasing r f q suppliers with links",
- inputSchema: {
+ inputSchema: z.object({
purchasingRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/quality.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/quality.ts
index d13e07bdf6..f08bb89247 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/quality.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/quality.ts
@@ -97,9 +97,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_activateGauge",
{
description: "activate gauge",
- inputSchema: {
+ inputSchema: z.object({
gaugeId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -112,9 +112,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deactivateGauge",
{
description: "deactivate gauge",
- inputSchema: {
+ inputSchema: z.object({
gaugeId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -127,9 +127,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteGauge",
{
description: "delete gauge",
- inputSchema: {
+ inputSchema: z.object({
gaugeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -142,9 +142,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteGaugeCalibrationRecord",
{
description: "delete gauge calibration record",
- inputSchema: {
+ inputSchema: z.object({
gaugeCalibrationRecordId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -157,9 +157,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteGaugeType",
{
description: "delete gauge type",
- inputSchema: {
+ inputSchema: z.object({
gaugeTypeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -172,9 +172,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteIssue",
{
description: "delete issue",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -187,10 +187,10 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteIssueAssociation",
{
description: "delete issue association",
- inputSchema: {
+ inputSchema: z.object({
type: z.string(),
associationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -203,9 +203,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteIssueType",
{
description: "delete issue type",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceTypeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -218,9 +218,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteIssueWorkflow",
{
description: "delete issue workflow",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceWorkflowId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -233,9 +233,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteRequiredAction",
{
description: "delete required action",
- inputSchema: {
+ inputSchema: z.object({
requiredActionId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -248,9 +248,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteQualityDocument",
{
description: "delete quality document",
- inputSchema: {
+ inputSchema: z.object({
qualityDocumentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -263,9 +263,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteQualityDocumentStep",
{
description: "delete quality document step",
- inputSchema: {
+ inputSchema: z.object({
qualityDocumentStepId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -278,9 +278,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_deleteRisk",
{
description: "delete risk",
- inputSchema: {
+ inputSchema: z.object({
riskId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -293,9 +293,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueFromExternalLink",
{
description: "get issue from external link",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -308,9 +308,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGauge",
{
description: "get gauge",
- inputSchema: {
+ inputSchema: z.object({
gaugeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -323,13 +323,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGauges",
{
description: "get gauges",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -342,7 +342,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugesList",
{
description: "get gauges list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -355,9 +355,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeCalibrationRecord",
{
description: "get gauge calibration record",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -370,13 +370,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeCalibrationRecords",
{
description: "get gauge calibration records",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -389,9 +389,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeCalibrationRecordsByGaugeId",
{
description: "get gauge calibration records by gauge id",
- inputSchema: {
+ inputSchema: z.object({
gaugeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -404,7 +404,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeTypesList",
{
description: "get gauge types list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -417,9 +417,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeType",
{
description: "get gauge type",
- inputSchema: {
+ inputSchema: z.object({
gaugeTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -432,13 +432,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getGaugeTypes",
{
description: "get gauge types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -451,9 +451,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssue",
{
description: "get issue",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -466,13 +466,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssues",
{
description: "get issues",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -485,9 +485,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueWorkflow",
{
description: "get issue workflow",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceWorkflowId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -500,9 +500,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueAction",
{
description: "get issue action",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -515,10 +515,10 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueActionTasks",
{
description: "get issue action tasks",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
supplierId: z.string().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -531,9 +531,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueApprovalTasks",
{
description: "get issue approval tasks",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -546,9 +546,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueItems",
{
description: "get issue items",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -561,9 +561,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueAssociations",
{
description: "get issue associations",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -576,9 +576,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueReviewers",
{
description: "get issue reviewers",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -591,9 +591,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueSuppliers",
{
description: "get issue suppliers",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -606,9 +606,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueTasks",
{
description: "get issue tasks",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -621,9 +621,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueType",
{
description: "get issue type",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -636,13 +636,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueTypes",
{
description: "get issue types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -655,13 +655,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueWorkflows",
{
description: "get issue workflows",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -674,7 +674,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueWorkflowsList",
{
description: "get issue workflows list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -687,7 +687,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getIssueTypesList",
{
description: "get issue types list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -700,13 +700,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityActions",
{
description: "get quality actions",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -719,9 +719,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityDocument",
{
description: "get quality document",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -734,9 +734,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityDocumentSteps",
{
description: "get quality document steps",
- inputSchema: {
+ inputSchema: z.object({
qualityDocumentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -749,12 +749,12 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityDocumentVersions",
{
description: "get quality document versions",
- inputSchema: {
+ inputSchema: z.object({
qualityDocument: z.object({
name: z.string(),
version: z.number()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -767,12 +767,12 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityDocuments",
{
description: "get quality documents",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -785,7 +785,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityDocumentsList",
{
description: "get quality documents list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -798,9 +798,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getQualityFiles",
{
description: "get quality files",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -813,7 +813,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getRequiredActionsList",
{
description: "get required actions list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -826,13 +826,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getRequiredActions",
{
description: "get required actions",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -845,9 +845,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getRequiredAction",
{
description: "get required action",
- inputSchema: {
+ inputSchema: z.object({
requiredActionId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -860,9 +860,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getRisk",
{
description: "get risk",
- inputSchema: {
+ inputSchema: z.object({
riskId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -875,7 +875,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_getRisks",
{
description: "get risks",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -884,7 +884,7 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
source: z.any().optional(),
assignee: z.array(z.string()).optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -897,9 +897,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_insertIssueReviewer",
{
description: "insert issue reviewer",
- inputSchema: {
+ inputSchema: z.object({
reviewer: nonConformanceReviewerValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -912,12 +912,12 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateIssueActionProcesses",
{
description: "update issue action processes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
actionTaskId: z.string(),
processIds: z.array(z.string())
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -930,14 +930,14 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateIssueStatus",
{
description: "update issue status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any(),
closeDate: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -950,14 +950,14 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateIssueTaskStatus",
{
description: "update issue task status",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
status: z.enum(["Pending", "Completed", "Skipped", "In Progress"]),
type: z.enum(["investigation", "action", "approval", "review"]),
assignee: z.string().nullable().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -970,13 +970,13 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateIssueTaskContent",
{
description: "update issue task content",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
type: z.enum(["action", "approval", "review"]),
content: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -989,12 +989,12 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateQualityDocumentStepOrder",
{
description: "update quality document step order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1007,10 +1007,10 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_updateRiskStatus",
{
description: "update risk status",
- inputSchema: {
+ inputSchema: z.object({
riskId: z.string(),
status: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1023,9 +1023,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertGauge",
{
description: "upsert gauge",
- inputSchema: {
+ inputSchema: z.object({
gauge: gaugeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1038,9 +1038,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertGaugeCalibrationRecord",
{
description: "upsert gauge calibration record",
- inputSchema: {
+ inputSchema: z.object({
gaugeCalibrationRecord: gaugeCalibrationRecordValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1053,9 +1053,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertGaugeType",
{
description: "upsert gauge type",
- inputSchema: {
+ inputSchema: z.object({
gaugeType: gaugeTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1068,9 +1068,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertIssue",
{
description: "upsert issue",
- inputSchema: {
+ inputSchema: z.object({
nonConformance: issueValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1083,9 +1083,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertIssueWorkflow",
{
description: "upsert issue workflow",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceWorkflow: issueWorkflowValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1098,9 +1098,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertIssueType",
{
description: "upsert issue type",
- inputSchema: {
+ inputSchema: z.object({
nonConformanceType: issueTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1113,9 +1113,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertRequiredAction",
{
description: "upsert required action",
- inputSchema: {
+ inputSchema: z.object({
requiredAction: issueTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1128,9 +1128,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertQualityDocument",
{
description: "upsert quality document",
- inputSchema: {
+ inputSchema: z.object({
qualityDocument: qualityDocumentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1143,9 +1143,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertQualityDocumentStep",
{
description: "upsert quality document step",
- inputSchema: {
+ inputSchema: z.object({
qualityDocumentStep: qualityDocumentStepValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1158,9 +1158,9 @@ export const registerQualityTools: RegisterTools = (server, ctx) => {
"quality_upsertRisk",
{
description: "upsert risk",
- inputSchema: {
+ inputSchema: z.object({
risk: riskRegisterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/resources.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/resources.ts
index 5a82f627ee..e89ffe86b7 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/resources.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/resources.ts
@@ -127,9 +127,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_activateWorkCenter",
{
description: "activate work center",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -142,10 +142,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteAbility",
{
description: "delete ability",
- inputSchema: {
+ inputSchema: z.object({
abilityId: z.string(),
hardDelete: z.boolean().optional(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -158,9 +158,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteContractor",
{
description: "delete contractor",
- inputSchema: {
+ inputSchema: z.object({
contractorId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -173,9 +173,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteEmployeeAbility",
{
description: "delete employee ability",
- inputSchema: {
+ inputSchema: z.object({
employeeAbilityId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -188,9 +188,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteFailureMode",
{
description: "delete failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureModeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -203,9 +203,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteLocation",
{
description: "delete location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -218,9 +218,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceDispatch",
{
description: "delete maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -233,9 +233,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceDispatchComment",
{
description: "delete maintenance dispatch comment",
- inputSchema: {
+ inputSchema: z.object({
commentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -248,9 +248,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceDispatchEvent",
{
description: "delete maintenance dispatch event",
- inputSchema: {
+ inputSchema: z.object({
eventId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -263,9 +263,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceDispatchItem",
{
description: "delete maintenance dispatch item",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -278,9 +278,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceDispatchWorkCenter",
{
description: "delete maintenance dispatch work center",
- inputSchema: {
+ inputSchema: z.object({
workCenterId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -293,9 +293,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceSchedule",
{
description: "delete maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -308,9 +308,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteMaintenanceScheduleItem",
{
description: "delete maintenance schedule item",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -323,9 +323,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deletePartner",
{
description: "delete partner",
- inputSchema: {
+ inputSchema: z.object({
partnerId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -338,9 +338,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_activateProcess",
{
description: "activate process",
- inputSchema: {
+ inputSchema: z.object({
processId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -353,9 +353,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_processDeactivate",
{
description: "process deactivate",
- inputSchema: {
+ inputSchema: z.object({
processId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -368,9 +368,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteProcess",
{
description: "delete process",
- inputSchema: {
+ inputSchema: z.object({
processId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -383,9 +383,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteShift",
{
description: "delete shift",
- inputSchema: {
+ inputSchema: z.object({
shiftId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -398,9 +398,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteSuggestion",
{
description: "delete suggestion",
- inputSchema: {
+ inputSchema: z.object({
suggestionId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -413,9 +413,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteTraining",
{
description: "delete training",
- inputSchema: {
+ inputSchema: z.object({
trainingId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -428,9 +428,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteTrainingAssignment",
{
description: "delete training assignment",
- inputSchema: {
+ inputSchema: z.object({
assignmentId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -443,9 +443,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteTrainingQuestion",
{
description: "delete training question",
- inputSchema: {
+ inputSchema: z.object({
trainingQuestionId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -458,9 +458,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_deleteWorkCenter",
{
description: "delete work center",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -473,13 +473,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getAbilities",
{
description: "get abilities",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -492,7 +492,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getAbilitiesList",
{
description: "get abilities list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -505,9 +505,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getAbility",
{
description: "get ability",
- inputSchema: {
+ inputSchema: z.object({
abilityId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -520,9 +520,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getContractor",
{
description: "get contractor",
- inputSchema: {
+ inputSchema: z.object({
contractorId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -535,13 +535,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getContractors",
{
description: "get contractors",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -554,9 +554,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getEmployeeAbilities",
{
description: "get employee abilities",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -569,9 +569,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getFailureMode",
{
description: "get failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureModeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -584,13 +584,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getFailureModes",
{
description: "get failure modes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -603,7 +603,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getFailureModesList",
{
description: "get failure modes list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -616,9 +616,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getLocation",
{
description: "get location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -631,13 +631,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getLocations",
{
description: "get locations",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -650,7 +650,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getLocationsList",
{
description: "get locations list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -663,9 +663,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatch",
{
description: "get maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -678,9 +678,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchComments",
{
description: "get maintenance dispatch comments",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -693,9 +693,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchEvents",
{
description: "get maintenance dispatch events",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -708,9 +708,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchItems",
{
description: "get maintenance dispatch items",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -723,9 +723,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchItemTrackedEntities",
{
description: "get maintenance dispatch item tracked entities",
- inputSchema: {
+ inputSchema: z.object({
maintenanceDispatchItemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -738,14 +738,14 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatches",
{
description: "get maintenance dispatches",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
status: z.string().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -758,7 +758,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchesByLocation",
{
description: "get maintenance dispatches by location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
@@ -766,7 +766,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
search: z.string().nullable(),
status: z.string().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -779,9 +779,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceDispatchWorkCenters",
{
description: "get maintenance dispatch work centers",
- inputSchema: {
+ inputSchema: z.object({
dispatchId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -794,9 +794,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceSchedule",
{
description: "get maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -809,9 +809,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceScheduleItems",
{
description: "get maintenance schedule items",
- inputSchema: {
+ inputSchema: z.object({
scheduleId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -824,14 +824,14 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceSchedules",
{
description: "get maintenance schedules",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
active: z.boolean().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -844,7 +844,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getMaintenanceSchedulesByLocation",
{
description: "get maintenance schedules by location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
args: z.object({
limit: z.number().int().default(100),
@@ -852,7 +852,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
search: z.string().nullable(),
active: z.boolean().optional()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -865,9 +865,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getOutstandingTrainingsForUser",
{
description: "get outstanding trainings for user",
- inputSchema: {
+ inputSchema: z.object({
employeeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -880,10 +880,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getPartner",
{
description: "get partner",
- inputSchema: {
+ inputSchema: z.object({
partnerId: z.string(),
abilityId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -896,9 +896,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getPartnerBySupplierId",
{
description: "get partner by supplier id",
- inputSchema: {
+ inputSchema: z.object({
partnerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -911,13 +911,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getPartners",
{
description: "get partners",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -930,9 +930,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getProcess",
{
description: "get process",
- inputSchema: {
+ inputSchema: z.object({
processId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -945,13 +945,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getProcesses",
{
description: "get processes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -964,7 +964,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getProcessesList",
{
description: "get processes list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -977,9 +977,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getSuggestion",
{
description: "get suggestion",
- inputSchema: {
+ inputSchema: z.object({
suggestionId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -992,13 +992,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getSuggestions",
{
description: "get suggestions",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1011,9 +1011,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTraining",
{
description: "get training",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1026,9 +1026,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingAssignment",
{
description: "get training assignment",
- inputSchema: {
+ inputSchema: z.object({
assignmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1041,9 +1041,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingAssignmentForCompletion",
{
description: "get training assignment for completion",
- inputSchema: {
+ inputSchema: z.object({
assignmentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1056,9 +1056,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingAssignments",
{
description: "get training assignments",
- inputSchema: {
+ inputSchema: z.object({
trainingId: z.string().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1071,12 +1071,12 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingAssignmentStatus",
{
description: "get training assignment status",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1089,7 +1089,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingAssignmentSummary",
{
description: "get training assignment summary",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1102,9 +1102,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingQuestions",
{
description: "get training questions",
- inputSchema: {
+ inputSchema: z.object({
trainingId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1117,12 +1117,12 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainings",
{
description: "get trainings",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1135,7 +1135,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getTrainingsList",
{
description: "get trainings list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1148,9 +1148,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getWorkCenter",
{
description: "get work center",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1163,12 +1163,12 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getWorkCenters",
{
description: "get work centers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1181,9 +1181,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getWorkCentersByLocation",
{
description: "get work centers by location",
- inputSchema: {
+ inputSchema: z.object({
locationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1196,7 +1196,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getWorkCentersList",
{
description: "get work centers list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1209,7 +1209,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_getWorkCentersListWithBlockingStatus",
{
description: "get work centers list with blocking status",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1222,7 +1222,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_insertAbility",
{
description: "insert ability",
- inputSchema: {
+ inputSchema: z.object({
ability: z.object({
name: z.string(),
curve: z.any(),
@@ -1231,7 +1231,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
value: z.number(),
shadowWeeks: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1244,10 +1244,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_insertEmployeeAbilities",
{
description: "insert employee abilities",
- inputSchema: {
+ inputSchema: z.object({
abilityId: z.string(),
employeeIds: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1260,14 +1260,14 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_insertTrainingCompletion",
{
description: "insert training completion",
- inputSchema: {
+ inputSchema: z.object({
completion: z.object({
trainingAssignmentId: z.string(),
employeeId: z.string(),
period: z.string().nullable(),
completedBy: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1280,10 +1280,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_updateAbility",
{
description: "update ability",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
ability: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1296,10 +1296,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_updateSuggestionEmoji",
{
description: "update suggestion emoji",
- inputSchema: {
+ inputSchema: z.object({
suggestionId: z.string(),
emoji: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1312,10 +1312,10 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_updateSuggestionTags",
{
description: "update suggestion tags",
- inputSchema: {
+ inputSchema: z.object({
suggestionId: z.string(),
tags: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1328,12 +1328,12 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_updateTrainingQuestionOrder",
{
description: "update training question order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1346,9 +1346,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertContractor",
{
description: "upsert contractor",
- inputSchema: {
+ inputSchema: z.object({
contractorWithAbilities: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1361,7 +1361,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertEmployeeAbility",
{
description: "upsert employee ability",
- inputSchema: {
+ inputSchema: z.object({
employeeAbility: z.object({
id: z.string().optional(),
abilityId: z.string(),
@@ -1369,7 +1369,7 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
trainingCompleted: z.boolean(),
trainingDays: z.number().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1382,9 +1382,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertFailureMode",
{
description: "upsert failure mode",
- inputSchema: {
+ inputSchema: z.object({
failureMode: failureModeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1397,9 +1397,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertLocation",
{
description: "upsert location",
- inputSchema: {
+ inputSchema: z.object({
location: locationValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1412,9 +1412,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceDispatch",
{
description: "upsert maintenance dispatch",
- inputSchema: {
+ inputSchema: z.object({
dispatch: maintenanceDispatchValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1427,9 +1427,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceDispatchComment",
{
description: "upsert maintenance dispatch comment",
- inputSchema: {
+ inputSchema: z.object({
comment: maintenanceDispatchCommentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1442,9 +1442,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceDispatchEvent",
{
description: "upsert maintenance dispatch event",
- inputSchema: {
+ inputSchema: z.object({
event: maintenanceDispatchEventValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1457,9 +1457,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceDispatchItem",
{
description: "upsert maintenance dispatch item",
- inputSchema: {
+ inputSchema: z.object({
item: maintenanceDispatchItemValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1472,9 +1472,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceDispatchWorkCenter",
{
description: "upsert maintenance dispatch work center",
- inputSchema: {
+ inputSchema: z.object({
workCenter: maintenanceDispatchWorkCenterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1487,9 +1487,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceSchedule",
{
description: "upsert maintenance schedule",
- inputSchema: {
+ inputSchema: z.object({
schedule: maintenanceScheduleValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1502,9 +1502,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertMaintenanceScheduleItem",
{
description: "upsert maintenance schedule item",
- inputSchema: {
+ inputSchema: z.object({
item: maintenanceScheduleItemValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1517,9 +1517,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertPartner",
{
description: "upsert partner",
- inputSchema: {
+ inputSchema: z.object({
partner: partnerValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1532,9 +1532,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertProcess",
{
description: "upsert process",
- inputSchema: {
+ inputSchema: z.object({
process: processValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1547,9 +1547,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertTraining",
{
description: "upsert training",
- inputSchema: {
+ inputSchema: z.object({
training: trainingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1562,13 +1562,13 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertTrainingAssignment",
{
description: "upsert training assignment",
- inputSchema: {
+ inputSchema: z.object({
assignment: z.object({
id: z.string().optional(),
trainingId: z.string(),
groupIds: z.array(z.string())
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1581,9 +1581,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertTrainingQuestion",
{
description: "upsert training question",
- inputSchema: {
+ inputSchema: z.object({
trainingQuestion: trainingQuestionValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1596,9 +1596,9 @@ export const registerResourcesTools: RegisterTools = (server, ctx) => {
"resources_upsertWorkCenter",
{
description: "upsert work center",
- inputSchema: {
+ inputSchema: z.object({
workCenter: workCenterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/sales.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/sales.ts
index 730da923a6..4be956a9cd 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/sales.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/sales.ts
@@ -197,9 +197,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_closeSalesOrder",
{
description: "close sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -212,11 +212,11 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_convertSalesRfqToQuote",
{
description: "convert sales rfq to quote",
- inputSchema: {
+ inputSchema: z.object({
payload: z.object({
id: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -229,9 +229,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_convertQuoteToOrder",
{
description: "convert quote to order",
- inputSchema: {
+ inputSchema: z.object({
payload: selectedLinesValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -244,9 +244,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_copyQuoteLine",
{
description: "copy quote line",
- inputSchema: {
+ inputSchema: z.object({
payload: getMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -259,9 +259,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_copyQuote",
{
description: "copy quote",
- inputSchema: {
+ inputSchema: z.object({
payload: getMethodValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -274,9 +274,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteCustomer",
{
description: "delete customer",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -289,10 +289,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteCustomerContact",
{
description: "delete customer contact",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
customerContactId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -305,10 +305,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteCustomerLocation",
{
description: "delete customer location",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
customerLocationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -321,9 +321,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteCustomerStatus",
{
description: "delete customer status",
- inputSchema: {
+ inputSchema: z.object({
customerStatusId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -336,9 +336,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteCustomerType",
{
description: "delete customer type",
- inputSchema: {
+ inputSchema: z.object({
customerTypeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -351,9 +351,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteNoQuoteReason",
{
description: "delete no quote reason",
- inputSchema: {
+ inputSchema: z.object({
noQuoteReasonId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -366,9 +366,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuote",
{
description: "delete quote",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -381,9 +381,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteMakeMethod",
{
description: "delete quote make method",
- inputSchema: {
+ inputSchema: z.object({
quoteMakeMethodId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -396,9 +396,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteLine",
{
description: "delete quote line",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -411,9 +411,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteMaterial",
{
description: "delete quote material",
- inputSchema: {
+ inputSchema: z.object({
quoteMaterialId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -426,9 +426,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteOperation",
{
description: "delete quote operation",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -441,9 +441,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteOperationStep",
{
description: "delete quote operation step",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -456,9 +456,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteOperationParameter",
{
description: "delete quote operation parameter",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -471,9 +471,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteQuoteOperationTool",
{
description: "delete quote operation tool",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -486,9 +486,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteSalesOrder",
{
description: "delete sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -501,9 +501,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteSalesOrderLine",
{
description: "delete sales order line",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -516,9 +516,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteSalesRFQ",
{
description: "delete sales r f q",
- inputSchema: {
+ inputSchema: z.object({
salesRfqId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -531,9 +531,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_deleteSalesRFQLine",
{
description: "delete sales r f q line",
- inputSchema: {
+ inputSchema: z.object({
salesRFQLineId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -546,9 +546,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getConfigurationParametersByQuoteLineId",
{
description: "get configuration parameters by quote line id",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -561,9 +561,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomer",
{
description: "get customer",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -576,9 +576,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerContact",
{
description: "get customer contact",
- inputSchema: {
+ inputSchema: z.object({
customerContactId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -591,9 +591,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerContacts",
{
description: "get customer contacts",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -606,9 +606,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerLocation",
{
description: "get customer location",
- inputSchema: {
+ inputSchema: z.object({
customerLocationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -621,9 +621,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerLocations",
{
description: "get customer locations",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -636,9 +636,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerPayment",
{
description: "get customer payment",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -651,9 +651,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerShipping",
{
description: "get customer shipping",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -666,13 +666,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomers",
{
description: "get customers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -685,7 +685,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomersList",
{
description: "get customers list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -698,9 +698,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerStatus",
{
description: "get customer status",
- inputSchema: {
+ inputSchema: z.object({
customerStatusId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -713,13 +713,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerStatuses",
{
description: "get customer statuses",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -732,7 +732,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerStatusesList",
{
description: "get customer statuses list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -745,9 +745,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerType",
{
description: "get customer type",
- inputSchema: {
+ inputSchema: z.object({
customerTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -760,13 +760,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerTypes",
{
description: "get customer types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -779,7 +779,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getCustomerTypesList",
{
description: "get customer types list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -792,14 +792,14 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getExternalSalesOrderLines",
{
description: "get external sales order lines",
- inputSchema: {
+ inputSchema: z.object({
customerId: z.string(),
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -812,9 +812,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getModelByQuoteLineId",
{
description: "get model by quote line id",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -827,7 +827,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getNoQuoteReasonsList",
{
description: "get no quote reasons list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -840,9 +840,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getNoQuoteReason",
{
description: "get no quote reason",
- inputSchema: {
+ inputSchema: z.object({
noQuoteReasonId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -855,13 +855,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getNoQuoteReasons",
{
description: "get no quote reasons",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -874,9 +874,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getOpportunity",
{
description: "get opportunity",
- inputSchema: {
+ inputSchema: z.object({
opportunityId: z.string().nullable(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -889,9 +889,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getOpportunityDocuments",
{
description: "get opportunity documents",
- inputSchema: {
+ inputSchema: z.object({
opportunityId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -904,10 +904,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getOpportunityLineDocuments",
{
description: "get opportunity line documents",
- inputSchema: {
+ inputSchema: z.object({
lineId: z.string(),
itemId: z.string().nullable().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -920,9 +920,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuote",
{
description: "get quote",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -935,7 +935,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteFavorites",
{
description: "get quote favorites",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -948,13 +948,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuotes",
{
description: "get quotes",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -967,7 +967,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuotesList",
{
description: "get quotes list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -980,9 +980,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteAssembliesByLine",
{
description: "get quote assemblies by line",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -995,9 +995,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteAssemblies",
{
description: "get quote assemblies",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1010,9 +1010,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteCustomerDetails",
{
description: "get quote customer details",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1025,9 +1025,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLine",
{
description: "get quote line",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1040,9 +1040,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLinesList",
{
description: "get quote lines list",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1055,9 +1055,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMakeMethod",
{
description: "get quote make method",
- inputSchema: {
+ inputSchema: z.object({
quoteMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1070,9 +1070,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getRootQuoteMakeMethod",
{
description: "get root quote make method",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1085,9 +1085,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMethodTrees",
{
description: "get quote method trees",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1100,9 +1100,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMethodTreeArray",
{
description: "get quote method tree array",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1115,9 +1115,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLines",
{
description: "get quote lines",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1130,9 +1130,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteByExternalId",
{
description: "get quote by external id",
- inputSchema: {
+ inputSchema: z.object({
externalId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1145,9 +1145,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLinePrices",
{
description: "get quote line prices",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1160,9 +1160,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLinePricesByQuoteId",
{
description: "get quote line prices by quote id",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1175,10 +1175,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLinePricesByItemId",
{
description: "get quote line prices by item id",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
currentQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1191,10 +1191,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteLinePricesByItemIds",
{
description: "get quote line prices by item ids",
- inputSchema: {
+ inputSchema: z.object({
itemIds: z.array(z.string()),
currentQuoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1207,9 +1207,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMaterials",
{
description: "get quote materials",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1222,9 +1222,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMaterial",
{
description: "get quote material",
- inputSchema: {
+ inputSchema: z.object({
materialId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1237,9 +1237,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMaterialsByLine",
{
description: "get quote materials by line",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1252,9 +1252,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMaterialsByMethodId",
{
description: "get quote materials by method id",
- inputSchema: {
+ inputSchema: z.object({
quoteMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1267,9 +1267,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteMaterialsByOperation",
{
description: "get quote materials by operation",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1282,9 +1282,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteOperation",
{
description: "get quote operation",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1297,9 +1297,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteOperationsByLine",
{
description: "get quote operations by line",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1312,9 +1312,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteOperationsByMethodId",
{
description: "get quote operations by method id",
- inputSchema: {
+ inputSchema: z.object({
quoteMakeMethodId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1327,9 +1327,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteOperations",
{
description: "get quote operations",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1342,9 +1342,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuotePayment",
{
description: "get quote payment",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1357,9 +1357,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getQuoteShipment",
{
description: "get quote shipment",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1372,10 +1372,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getRelatedPricesForQuoteLine",
{
description: "get related prices for quote line",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
quoteId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1388,7 +1388,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesDocumentsAssignedToMe",
{
description: "get sales documents assigned to me",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1401,9 +1401,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrder",
{
description: "get sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1416,9 +1416,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderCustomerDetails",
{
description: "get sales order customer details",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1431,7 +1431,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderFavorites",
{
description: "get sales order favorites",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1444,10 +1444,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderRelatedItems",
{
description: "get sales order related items",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
opportunityId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1460,7 +1460,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrders",
{
description: "get sales orders",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
@@ -1468,7 +1468,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
status: z.string().nullable(),
customerId: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1481,7 +1481,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrdersList",
{
description: "get sales orders list",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1494,9 +1494,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderPayment",
{
description: "get sales order payment",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1509,7 +1509,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesTerms",
{
description: "get sales terms",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1522,9 +1522,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderShipment",
{
description: "get sales order shipment",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1537,7 +1537,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderCustomers",
{
description: "get sales order customers",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1550,9 +1550,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderLines",
{
description: "get sales order lines",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1565,9 +1565,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderInvoiceLines",
{
description: "get sales order invoice lines",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1580,9 +1580,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderInvoicesByIds",
{
description: "get sales order invoices by ids",
- inputSchema: {
+ inputSchema: z.object({
invoiceIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1595,9 +1595,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderLinesByItemId",
{
description: "get sales order lines by item id",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1610,9 +1610,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderLinesByItemIds",
{
description: "get sales order lines by item ids",
- inputSchema: {
+ inputSchema: z.object({
itemIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1625,9 +1625,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderLine",
{
description: "get sales order line",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1640,9 +1640,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesOrderLineShipments",
{
description: "get sales order line shipments",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1655,9 +1655,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesRFQ",
{
description: "get sales r f q",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1670,7 +1670,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesRFQFavorites",
{
description: "get sales r f q favorites",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1683,13 +1683,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesRFQs",
{
description: "get sales r f qs",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1702,9 +1702,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesRFQLine",
{
description: "get sales r f q line",
- inputSchema: {
+ inputSchema: z.object({
lineId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1717,9 +1717,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_getSalesRFQLines",
{
description: "get sales r f q lines",
- inputSchema: {
+ inputSchema: z.object({
salesRfqId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1732,9 +1732,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_insertCustomerContact",
{
description: "insert customer contact",
- inputSchema: {
+ inputSchema: z.object({
customerContact: customerContactValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1747,7 +1747,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_insertCustomerLocation",
{
description: "insert customer location",
- inputSchema: {
+ inputSchema: z.object({
customerLocation: z.object({
customerId: z.string(),
name: z.string(),
@@ -1760,7 +1760,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
postalCode: z.string().optional(),
customFields: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1773,9 +1773,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_insertSalesOrderLines",
{
description: "insert sales order lines",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLines: salesOrderLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1788,9 +1788,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_finalizeQuote",
{
description: "finalize quote",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1803,9 +1803,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_releaseSalesOrder",
{
description: "release sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrderId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1818,9 +1818,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertCustomer",
{
description: "upsert customer",
- inputSchema: {
+ inputSchema: z.object({
customer: customerValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1833,9 +1833,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateCustomerAccounting",
{
description: "update customer accounting",
- inputSchema: {
+ inputSchema: z.object({
customerAccounting: customerAccountingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1848,9 +1848,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateCustomerContact",
{
description: "update customer contact",
- inputSchema: {
+ inputSchema: z.object({
customerContact: customerContactValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1863,7 +1863,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateCustomerLocation",
{
description: "update customer location",
- inputSchema: {
+ inputSchema: z.object({
customerLocation: z.object({
addressId: z.string(),
name: z.string(),
@@ -1876,7 +1876,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
postalCode: z.string().optional(),
customFields: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1889,9 +1889,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateCustomerPayment",
{
description: "update customer payment",
- inputSchema: {
+ inputSchema: z.object({
customerPayment: customerPaymentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1904,9 +1904,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateCustomerShipping",
{
description: "update customer shipping",
- inputSchema: {
+ inputSchema: z.object({
customerShipping: customerShippingValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1919,9 +1919,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertCustomerStatus",
{
description: "upsert customer status",
- inputSchema: {
+ inputSchema: z.object({
customerStatus: customerStatusValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1934,9 +1934,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertCustomerType",
{
description: "upsert customer type",
- inputSchema: {
+ inputSchema: z.object({
customerType: customerTypeValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1949,9 +1949,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertNoQuoteReason",
{
description: "upsert no quote reason",
- inputSchema: {
+ inputSchema: z.object({
noQuoteReason: noQuoteReasonValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1964,12 +1964,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesRFQFavorite",
{
description: "update sales r f q favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1982,12 +1982,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesRFQLineOrder",
{
description: "update sales r f q line order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2000,12 +2000,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteExchangeRate",
{
description: "update quote exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2018,10 +2018,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteLinePrecision",
{
description: "update quote line precision",
- inputSchema: {
+ inputSchema: z.object({
quoteLineId: z.string(),
precision: z.number(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2034,12 +2034,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesOrderExchangeRate",
{
description: "update sales order exchange rate",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
id: z.string(),
exchangeRate: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2052,12 +2052,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteFavorite",
{
description: "update quote favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2070,14 +2070,14 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesRFQStatus",
{
description: "update sales r f q status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
noQuoteReasonId: z.string().nullable(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2090,12 +2090,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteMaterialOrder",
{
description: "update quote material order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2108,12 +2108,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteOperationOrder",
{
description: "update quote operation order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
order: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2126,13 +2126,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateQuoteStatus",
{
description: "update quote status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2145,7 +2145,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertMakeMethodFromQuoteLine",
{
description: "upsert make method from quote line",
- inputSchema: {
+ inputSchema: z.object({
lineMethod: z.object({
itemId: z.string(),
quoteId: z.string(),
@@ -2158,7 +2158,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2171,7 +2171,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertMakeMethodFromQuoteMethod",
{
description: "upsert make method from quote method",
- inputSchema: {
+ inputSchema: z.object({
quoteMethod: z.object({
sourceId: z.string(),
targetId: z.string(),
@@ -2183,7 +2183,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2196,9 +2196,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuote",
{
description: "upsert quote",
- inputSchema: {
+ inputSchema: z.object({
quote: quoteValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2211,9 +2211,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteLine",
{
description: "upsert quote line",
- inputSchema: {
+ inputSchema: z.object({
quotationLine: quoteLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2226,10 +2226,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteLineAdditionalCharges",
{
description: "upsert quote line additional charges",
- inputSchema: {
+ inputSchema: z.object({
lineId: z.string(),
update: quoteLineAdditionalChargesValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2242,7 +2242,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteLinePrices",
{
description: "upsert quote line prices",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
lineId: z.string(),
quoteLinePrices: z.object({
@@ -2253,7 +2253,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
quantity: z.number(),
categoryMarkups: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2266,11 +2266,11 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_calculatePricesForQuantities",
{
description: "calculate prices for quantities",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
quoteLineId: z.string(),
quantities: z.array(z.number()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2283,10 +2283,10 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_recalculateQuoteLinePrices",
{
description: "recalculate quote line prices",
- inputSchema: {
+ inputSchema: z.object({
quoteId: z.string(),
quoteLineId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2299,7 +2299,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteLineMethod",
{
description: "upsert quote line method",
- inputSchema: {
+ inputSchema: z.object({
lineMethod: z.object({
itemId: z.string(),
quoteId: z.string(),
@@ -2313,7 +2313,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2326,9 +2326,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteMaterial",
{
description: "upsert quote material",
- inputSchema: {
+ inputSchema: z.object({
quoteMaterial: quoteMaterialValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2341,7 +2341,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteMaterialMakeMethod",
{
description: "upsert quote material make method",
- inputSchema: {
+ inputSchema: z.object({
quoteMethod: z.object({
sourceId: z.string(),
targetId: z.string(),
@@ -2354,7 +2354,7 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
steps: z.boolean(),
workInstructions: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2367,9 +2367,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteOperation",
{
description: "upsert quote operation",
- inputSchema: {
+ inputSchema: z.object({
operation: quoteOperationValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2382,9 +2382,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteOperationStep",
{
description: "upsert quote operation step",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationStep: operationStepValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2397,9 +2397,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteOperationParameter",
{
description: "upsert quote operation parameter",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationParameter: operationParameterValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2412,9 +2412,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteOperationTool",
{
description: "upsert quote operation tool",
- inputSchema: {
+ inputSchema: z.object({
quoteOperationTool: operationToolValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2427,9 +2427,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuotePayment",
{
description: "upsert quote payment",
- inputSchema: {
+ inputSchema: z.object({
quotePayment: quotePaymentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2442,9 +2442,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertQuoteShipment",
{
description: "upsert quote shipment",
- inputSchema: {
+ inputSchema: z.object({
quoteShipment: quoteShipmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2457,12 +2457,12 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesOrderFavorite",
{
description: "update sales order favorite",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
id: z.string(),
favorite: z.boolean()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2475,13 +2475,13 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_updateSalesOrderStatus",
{
description: "update sales order status",
- inputSchema: {
+ inputSchema: z.object({
update: z.object({
id: z.string(),
status: z.any(),
assignee: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2494,9 +2494,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesOrder",
{
description: "upsert sales order",
- inputSchema: {
+ inputSchema: z.object({
salesOrder: salesOrderValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2509,9 +2509,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesOrderShipment",
{
description: "upsert sales order shipment",
- inputSchema: {
+ inputSchema: z.object({
salesOrderShipment: salesOrderShipmentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2524,9 +2524,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesOrderLine",
{
description: "upsert sales order line",
- inputSchema: {
+ inputSchema: z.object({
salesOrderLine: salesOrderLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2539,9 +2539,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesOrderPayment",
{
description: "upsert sales order payment",
- inputSchema: {
+ inputSchema: z.object({
salesOrderPayment: salesOrderPaymentValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2554,9 +2554,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesRFQ",
{
description: "upsert sales r f q",
- inputSchema: {
+ inputSchema: z.object({
rfq: salesRfqValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -2569,9 +2569,9 @@ export const registerSalesTools: RegisterTools = (server, ctx) => {
"sales_upsertSalesRFQLine",
{
description: "upsert sales r f q line",
- inputSchema: {
+ inputSchema: z.object({
salesRfqLine: salesRfqLineValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/settings.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/settings.ts
index fab8faa99f..78f3b9d35e 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/settings.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/settings.ts
@@ -93,7 +93,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getAccountsPayableBillingAddress",
{
description: "get accounts payable billing address",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -106,7 +106,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getAccountsReceivableBillingAddress",
{
description: "get accounts receivable billing address",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -119,9 +119,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsPayableBillingAddress",
{
description: "update accounts payable billing address",
- inputSchema: {
+ inputSchema: z.object({
data: accountsPayableBillingAddressValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -134,9 +134,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsReceivableBillingAddress",
{
description: "update accounts receivable billing address",
- inputSchema: {
+ inputSchema: z.object({
data: accountsReceivableBillingAddressValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -149,9 +149,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_deleteApiKey",
{
description: "delete api key",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -164,9 +164,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_deleteWebhook",
{
description: "delete webhook",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -179,7 +179,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_deactivateWebhooks",
{
description: "deactivate webhooks",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -192,13 +192,13 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getApiKeys",
{
description: "get api keys",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -211,7 +211,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCompanies",
{
description: "get companies",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -224,7 +224,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCompany",
{
description: "get company",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -237,7 +237,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCompanyPlan",
{
description: "get company plan",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -250,7 +250,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCompanySettings",
{
description: "get company settings",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -263,7 +263,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCompanyIntegrations",
{
description: "get company integrations",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -276,7 +276,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getConfig",
{
description: "get config",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -289,9 +289,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCurrentSequence",
{
description: "get current sequence",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -304,9 +304,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCustomField",
{
description: "get custom field",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -319,9 +319,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCustomFields",
{
description: "get custom fields",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -334,13 +334,13 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getCustomFieldsTables",
{
description: "get custom fields tables",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -353,9 +353,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getIntegration",
{
description: "get integration",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -368,7 +368,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getIntegrations",
{
description: "get integrations",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -381,7 +381,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getKanbanOutputSetting",
{
description: "get kanban output setting",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -394,9 +394,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getPlanById",
{
description: "get plan by id",
- inputSchema: {
+ inputSchema: z.object({
planId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -409,7 +409,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getPlans",
{
description: "get plans",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -422,9 +422,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getNextSequence",
{
description: "get next sequence",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -437,9 +437,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getSequence",
{
description: "get sequence",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -452,13 +452,13 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getSequences",
{
description: "get sequences",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -471,9 +471,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getSequencesList",
{
description: "get sequences list",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -486,7 +486,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getTerms",
{
description: "get terms",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -499,9 +499,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getWebhook",
{
description: "get webhook",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -514,7 +514,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getWebhookTables",
{
description: "get webhook tables",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -527,13 +527,13 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_getWebhooks",
{
description: "get webhooks",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -546,10 +546,10 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_insertCompany",
{
description: "insert company",
- inputSchema: {
+ inputSchema: z.object({
company: companyValidator,
ownerId: z.string().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -562,14 +562,14 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateCompanyPlan",
{
description: "update company plan",
- inputSchema: {
+ inputSchema: z.object({
data: z.object({
stripeCustomerId: z.string(),
stripeSubscriptionId: z.string(),
stripeSubscriptionStatus: z.string(),
subscriptionStartDate: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -582,7 +582,7 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_seedCompany",
{
description: "seed company",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -595,9 +595,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateCompany",
{
description: "update company",
- inputSchema: {
+ inputSchema: z.object({
company: companyValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -610,9 +610,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateKanbanOutputSetting",
{
description: "update kanban output setting",
- inputSchema: {
+ inputSchema: z.object({
kanbanOutput: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -625,9 +625,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateMetricSettings",
{
description: "update metric settings",
- inputSchema: {
+ inputSchema: z.object({
useMetric: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -640,9 +640,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_upsertApiKey",
{
description: "upsert api key",
- inputSchema: {
+ inputSchema: z.object({
apiKey: apiKeyValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -655,11 +655,11 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateDigitalQuoteSetting",
{
description: "update digital quote setting",
- inputSchema: {
+ inputSchema: z.object({
digitalQuoteEnabled: z.boolean(),
digitalQuoteNotificationGroup: z.array(z.string()),
digitalQuoteIncludesPurchaseOrders: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -672,9 +672,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateLogoDark",
{
description: "update logo dark",
- inputSchema: {
+ inputSchema: z.object({
logoDark: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -687,9 +687,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateLogoLight",
{
description: "update logo light",
- inputSchema: {
+ inputSchema: z.object({
logoLight: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -702,9 +702,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateLogoDarkIcon",
{
description: "update logo dark icon",
- inputSchema: {
+ inputSchema: z.object({
logoDarkIcon: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -717,9 +717,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateLogoLightIcon",
{
description: "update logo light icon",
- inputSchema: {
+ inputSchema: z.object({
logoLightIcon: z.string().nullable(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -732,9 +732,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateMaterialGeneratedIdsSetting",
{
description: "update material generated ids setting",
- inputSchema: {
+ inputSchema: z.object({
materialGeneratedIds: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -747,9 +747,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateMaterialUnitsSetting",
{
description: "update material units setting",
- inputSchema: {
+ inputSchema: z.object({
useMetric: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -762,9 +762,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateProductLabelSize",
{
description: "update product label size",
- inputSchema: {
+ inputSchema: z.object({
productLabelSize: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -777,9 +777,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updatePurchasingPdfThumbnails",
{
description: "update purchasing pdf thumbnails",
- inputSchema: {
+ inputSchema: z.object({
includeThumbnailsOnPurchasingPdfs: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -792,9 +792,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateSalesPdfThumbnails",
{
description: "update sales pdf thumbnails",
- inputSchema: {
+ inputSchema: z.object({
includeThumbnailsOnSalesPdfs: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -807,9 +807,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateJobTravelerWorkInstructions",
{
description: "update job traveler work instructions",
- inputSchema: {
+ inputSchema: z.object({
jobTravelerIncludeWorkInstructions: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -822,9 +822,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateTimeCardSetting",
{
description: "update time card setting",
- inputSchema: {
+ inputSchema: z.object({
timeCardEnabled: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -837,9 +837,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateConsoleSetting",
{
description: "update console setting",
- inputSchema: {
+ inputSchema: z.object({
consoleEnabled: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -852,9 +852,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateRfqReadySetting",
{
description: "update rfq ready setting",
- inputSchema: {
+ inputSchema: z.object({
rfqReadyNotificationGroup: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -867,9 +867,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateSuggestionNotificationSetting",
{
description: "update suggestion notification setting",
- inputSchema: {
+ inputSchema: z.object({
suggestionNotificationGroup: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -882,14 +882,14 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateMaintenanceDispatchNotificationSettings",
{
description: "update maintenance dispatch notification settings",
- inputSchema: {
+ inputSchema: z.object({
settings: z.object({
maintenanceDispatchNotificationGroup: z.array(z.string()).optional(),
qualityDispatchNotificationGroup: z.array(z.string()).optional(),
operationsDispatchNotificationGroup: z.array(z.string()).optional(),
otherDispatchNotificationGroup: z.array(z.string()).optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -902,9 +902,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateSupplierQuoteNotificationSetting",
{
description: "update supplier quote notification setting",
- inputSchema: {
+ inputSchema: z.object({
supplierQuoteNotificationGroup: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -917,9 +917,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updatePurchasePriceUpdateTimingSetting",
{
description: "update purchase price update timing setting",
- inputSchema: {
+ inputSchema: z.object({
purchasePriceUpdateTiming: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -932,9 +932,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateLeadTimesOnReceiptSetting",
{
description: "update lead times on receipt setting",
- inputSchema: {
+ inputSchema: z.object({
updateLeadTimesOnReceipt: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -947,9 +947,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateSupplierApprovalSetting",
{
description: "update supplier approval setting",
- inputSchema: {
+ inputSchema: z.object({
supplierApproval: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -962,9 +962,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsPayableAddressSetting",
{
description: "update accounts payable address setting",
- inputSchema: {
+ inputSchema: z.object({
accountsPayableAddress: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -977,9 +977,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsReceivableAddressSetting",
{
description: "update accounts receivable address setting",
- inputSchema: {
+ inputSchema: z.object({
accountsReceivableAddress: z.boolean(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -992,9 +992,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsPayableEmail",
{
description: "update accounts payable email",
- inputSchema: {
+ inputSchema: z.object({
accountsPayableEmail: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1007,9 +1007,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateAccountsReceivableEmail",
{
description: "update accounts receivable email",
- inputSchema: {
+ inputSchema: z.object({
accountsReceivableEmail: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1022,9 +1022,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateDefaultSupplierCc",
{
description: "update default supplier cc",
- inputSchema: {
+ inputSchema: z.object({
defaultSupplierCc: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1037,9 +1037,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateDefaultCustomerCc",
{
description: "update default customer cc",
- inputSchema: {
+ inputSchema: z.object({
defaultCustomerCc: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1052,9 +1052,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateQuoteLineCategoryMarkups",
{
description: "update quote line category markups",
- inputSchema: {
+ inputSchema: z.object({
quoteLineCategoryMarkups: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1067,10 +1067,10 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateSequence",
{
description: "update sequence",
- inputSchema: {
+ inputSchema: z.object({
table: z.string(),
sequence: sequenceValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1083,10 +1083,10 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_updateIntegrationMetadata",
{
description: "update integration metadata",
- inputSchema: {
+ inputSchema: z.object({
integrationId: z.string(),
metadata: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -1099,9 +1099,9 @@ export const registerSettingsTools: RegisterTools = (server, ctx) => {
"settings_upsertWebhook",
{
description: "upsert webhook",
- inputSchema: {
+ inputSchema: z.object({
webhook: webhookValidator,
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/shared.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/shared.ts
index 155a0a920a..19c64a8cc7 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/shared.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/shared.ts
@@ -61,11 +61,11 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_approveRequest",
{
description: "approve request",
- inputSchema: {
+ inputSchema: z.object({
db: z.any(),
id: z.string(),
notes: z.string().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -78,9 +78,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_canApproveRequest",
{
description: "can approve request",
- inputSchema: {
+ inputSchema: z.object({
approvalRequest: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -93,9 +93,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_canApproveRequestInWindow",
{
description: "can approve request in window",
- inputSchema: {
+ inputSchema: z.object({
approvalRequest: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -108,9 +108,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_cancelApprovalRequest",
{
description: "cancel approval request",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -123,9 +123,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_canViewApprovalRequest",
{
description: "can view approval request",
- inputSchema: {
+ inputSchema: z.object({
approvalRequest: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -138,9 +138,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_createApprovalRequest",
{
description: "create approval request",
- inputSchema: {
+ inputSchema: z.object({
request: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -153,9 +153,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_deleteApprovalRule",
{
description: "delete approval rule",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -168,9 +168,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_deleteNote",
{
description: "delete note",
- inputSchema: {
+ inputSchema: z.object({
noteId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -183,9 +183,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_deleteSavedView",
{
description: "delete saved view",
- inputSchema: {
+ inputSchema: z.object({
viewId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -198,9 +198,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_generateEmbedding",
{
description: "generate embedding",
- inputSchema: {
+ inputSchema: z.object({
text: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -213,9 +213,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalById",
{
description: "get approval by id",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -228,10 +228,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalRequestsByDocument",
{
description: "get approval requests by document",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
documentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -244,10 +244,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalRuleByAmount",
{
description: "get approval rule by amount",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
amount: z.number().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -260,9 +260,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApproverUserIdsForRule",
{
description: "get approver user ids for rule",
- inputSchema: {
+ inputSchema: z.object({
rule: z.any(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -275,9 +275,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalRuleById",
{
description: "get approval rule by id",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -290,7 +290,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalRules",
{
description: "get approval rules",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -303,9 +303,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalRulesForApprover",
{
description: "get approval rules for approver",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -318,12 +318,12 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getApprovalsForUser",
{
description: "get approvals for user",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0)
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -336,9 +336,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getBase64ImageFromSupabase",
{
description: "get base64 image from supabase",
- inputSchema: {
+ inputSchema: z.object({
path: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -351,7 +351,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getCountries",
{
description: "get countries",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -364,10 +364,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getLatestApprovalRequestForDocument",
{
description: "get latest approval request for document",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
documentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -380,9 +380,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getModelByItemId",
{
description: "get model by item id",
- inputSchema: {
+ inputSchema: z.object({
itemId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -395,9 +395,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getNotes",
{
description: "get notes",
- inputSchema: {
+ inputSchema: z.object({
documentId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -410,7 +410,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getPendingApprovalsForApprover",
{
description: "get pending approvals for approver",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -423,12 +423,12 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getPeriods",
{
description: "get periods",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
startDate: z.string(),
endDate: z.string()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -441,7 +441,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getSavedViews",
{
description: "get saved views",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -454,9 +454,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getTagsList",
{
description: "get tags list",
- inputSchema: {
+ inputSchema: z.object({
table: z.string().nullable().optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -469,10 +469,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_hasPendingApproval",
{
description: "has pending approval",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
documentId: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -485,14 +485,14 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_importCsv",
{
description: "import csv",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
table: z.string(),
filePath: z.string(),
columnMappings: z.any(),
enumMappings: z.any().optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -505,12 +505,12 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_insertNote",
{
description: "insert note",
- inputSchema: {
+ inputSchema: z.object({
note: z.object({
note: z.string(),
documentId: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -523,9 +523,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_insertTag",
{
description: "insert tag",
- inputSchema: {
+ inputSchema: z.object({
tag: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -538,10 +538,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_isApprovalRequired",
{
description: "is approval required",
- inputSchema: {
+ inputSchema: z.object({
documentType: z.any(),
amount: z.number().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -554,9 +554,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getExternalLink",
{
description: "get external link",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -569,9 +569,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_upsertExternalLink",
{
description: "upsert external link",
- inputSchema: {
+ inputSchema: z.object({
externalLink: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -584,13 +584,13 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getCustomerPortals",
{
description: "get customer portals",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -603,9 +603,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_getCustomerPortal",
{
description: "get customer portal",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -618,9 +618,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_deleteCustomerPortal",
{
description: "delete customer portal",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -633,10 +633,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_updateModelThumbnail",
{
description: "update model thumbnail",
- inputSchema: {
+ inputSchema: z.object({
modelId: z.string(),
thumbnailPath: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -649,9 +649,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_upsertModelUpload",
{
description: "upsert model upload",
- inputSchema: {
+ inputSchema: z.object({
upload: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -664,10 +664,10 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_updateNote",
{
description: "update note",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
note: z.string(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -680,11 +680,11 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_rejectRequest",
{
description: "reject request",
- inputSchema: {
+ inputSchema: z.object({
db: z.any(),
id: z.string(),
notes: z.string().optional(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -697,9 +697,9 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_upsertApprovalRule",
{
description: "upsert approval rule",
- inputSchema: {
+ inputSchema: z.object({
rule: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -712,7 +712,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_upsertSavedView",
{
description: "upsert saved view",
- inputSchema: {
+ inputSchema: z.object({
view: z.object({
id: z.string().optional(),
name: z.string(),
@@ -725,7 +725,7 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
columnVisibility: z.any().optional(),
columnOrder: z.array(z.string()).optional()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -738,12 +738,12 @@ export const registerSharedTools: RegisterTools = (server, ctx) => {
"shared_updateSavedViewOrder",
{
description: "update saved view order",
- inputSchema: {
+ inputSchema: z.object({
updates: z.object({
id: z.string(),
sortOrder: z.number()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/tools/users.ts b/apps/erp/app/routes/api+/mcp+/lib/tools/users.ts
index 9b5ed0e9cd..d7c22d28ed 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/tools/users.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/tools/users.ts
@@ -42,9 +42,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_deleteEmployeeType",
{
description: "delete employee type",
- inputSchema: {
+ inputSchema: z.object({
employeeTypeId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -57,9 +57,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_deleteGroup",
{
description: "delete group",
- inputSchema: {
+ inputSchema: z.object({
groupId: z.string(),
- },
+ }),
annotations: DESTRUCTIVE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -72,7 +72,7 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getCompaniesForUser",
{
description: "get companies for user",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -85,13 +85,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getCustomers",
{
description: "get customers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -104,9 +104,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getEmployee",
{
description: "get employee",
- inputSchema: {
+ inputSchema: z.object({
id: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -119,13 +119,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getEmployees",
{
description: "get employees",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -138,13 +138,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getConsoleOperators",
{
description: "get console operators",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -157,9 +157,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getEmployeeType",
{
description: "get employee type",
- inputSchema: {
+ inputSchema: z.object({
employeeTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -172,13 +172,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getEmployeeTypes",
{
description: "get employee types",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -191,7 +191,7 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getInvitable",
{
description: "get invitable",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -204,7 +204,7 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getModules",
{
description: "get modules",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -217,9 +217,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getGroup",
{
description: "get group",
- inputSchema: {
+ inputSchema: z.object({
groupId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -232,9 +232,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getGroupMembers",
{
description: "get group members",
- inputSchema: {
+ inputSchema: z.object({
groupId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -247,14 +247,14 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getGroups",
{
description: "get groups",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable(),
uid: z.string().nullable()
}).optional(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -267,9 +267,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getGroupEmails",
{
description: "get group emails",
- inputSchema: {
+ inputSchema: z.object({
groupIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -282,9 +282,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getPermissionsByEmployeeType",
{
description: "get permissions by employee type",
- inputSchema: {
+ inputSchema: z.object({
employeeTypeId: z.string(),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -297,13 +297,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getSuppliers",
{
description: "get suppliers",
- inputSchema: {
+ inputSchema: z.object({
args: z.object({
limit: z.number().int().default(100),
offset: z.number().int().default(0),
search: z.string().nullable()
}),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -316,7 +316,7 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getUsers",
{
description: "get users",
- inputSchema: {},
+ inputSchema: z.object({}),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -329,9 +329,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_getUserEmails",
{
description: "get user emails",
- inputSchema: {
+ inputSchema: z.object({
userIds: z.array(z.string()),
- },
+ }),
annotations: READ_ONLY_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -344,11 +344,11 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_insertEmployeeType",
{
description: "insert employee type",
- inputSchema: {
+ inputSchema: z.object({
employeeType: z.object({
name: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -361,11 +361,11 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_insertGroup",
{
description: "insert group",
- inputSchema: {
+ inputSchema: z.object({
group: z.object({
name: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -378,9 +378,9 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_upsertEmployeeType",
{
description: "upsert employee type",
- inputSchema: {
+ inputSchema: z.object({
employeeType: z.any(),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -393,13 +393,13 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_upsertEmployeeTypePermissions",
{
description: "upsert employee type permissions",
- inputSchema: {
+ inputSchema: z.object({
employeeTypeId: z.string(),
permissions: z.object({
name: z.string(),
permission: z.any()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -412,12 +412,12 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_upsertGroup",
{
description: "upsert group",
- inputSchema: {
+ inputSchema: z.object({
arg1: z.object({
id: z.string(),
name: z.string()
}),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
@@ -430,10 +430,10 @@ export const registerUsersTools: RegisterTools = (server, ctx) => {
"users_upsertGroupMembers",
{
description: "upsert group members",
- inputSchema: {
+ inputSchema: z.object({
groupId: z.string(),
selections: z.array(z.string()),
- },
+ }),
annotations: WRITE_ANNOTATIONS,
},
withErrorHandling(async (params) => {
diff --git a/apps/erp/app/routes/api+/mcp+/lib/types.ts b/apps/erp/app/routes/api+/mcp+/lib/types.ts
index 2716b8185d..80a2c06425 100644
--- a/apps/erp/app/routes/api+/mcp+/lib/types.ts
+++ b/apps/erp/app/routes/api+/mcp+/lib/types.ts
@@ -58,8 +58,21 @@ export function withErrorHandling<T extends Record<string, unknown>>(
) {
return async (params: T) => {
try {
- return await handler(params);
+ console.log(
+ `[withErrorHandling] Executing handler for: ${fallbackMessage}`
+ );
+ const result = await handler(params);
+ console.log(`[withErrorHandling] Handler completed successfully`);
+ return result;
} catch (error) {
+ console.error(
+ `[withErrorHandling] Error in handler (${fallbackMessage}):`,
+ error
+ );
+ console.error(
+ `[withErrorHandling] Error stack:`,
+ error instanceof Error ? error.stack : "No stack"
+ );
return {
content: [
{
diff --git a/docker-compose.yml b/docker-compose.yml
new file mode 100644
index 0000000000..bac6638649
--- /dev/null
+++ b/docker-compose.yml
@@ -0,0 +1,21 @@
+version: '3.8'
+
+services:
+ redis:
+ image: redis:7-alpine
+ container_name: carbon-redis
+ ports:
+ - "6379:6379"
+ volumes:
+ - redis-data:/data
+ command: redis-server --appendonly yes
+ healthcheck:
+ test: ["CMD", "redis-cli", "ping"]
+ interval: 5s
+ timeout: 3s
+ retries: 5
+ restart: unless-stopped
+
+volumes:
+ redis-data:
+ driver: local
\ No newline at end of file
diff --git a/package.json b/package.json
index 7cbb610d3b..d402117462 100755
--- a/package.json
+++ b/package.json
@@ -54,7 +54,8 @@
"db:stop": "npm run db:stop -w @carbon/database",
"db:types": "npm run db:types -w @carbon/database",
"deploy": "turbo run deploy",
- "dev": "run-p dev:jobs dev:jobs-wait",
+ "dev": "run-p dev:docker dev:jobs dev:jobs-wait",
+ "dev:docker": "docker-compose up -d redis",
"dev:jobs-wait": "npx wait-on tcp:8288 && run-p dev:erp dev:stripe",
"dev:academy": "turbo run dev --filter=./apps/academy --filter=./packages/",
"dev:erp": "turbo run dev --filter=./apps/erp --filter=./packages/ ",
diff --git a/scripts/generate-mcp.ts b/scripts/generate-mcp.ts
index 86098f9ef3..6de2578527 100644
--- a/scripts/generate-mcp.ts
+++ b/scripts/generate-mcp.ts
@@ -1,909 +1,117 @@
/**
- * MCP Tool Code Generator
+ * Generate MCP tool metadata for JIT loading
+ * This runs as part of generate-mcp.ts to create a metadata file
+ * that can be imported without loading all tool implementations.
*
- * Parses all *.service.ts files and generates:
- * 1. Tool registration files in apps/erp/app/modules/mcp/tools/
- * 2. Documentation in llm/cache/mcp-tools-reference.md
- *
- * Usage: npx tsx scripts/generate-mcp.ts
+ * Tools listed in apps/erp/.../mcp-blocked-tools.ts are omitted from metadata
+ * (and blocked at runtime) so they never appear in search_tools / describe_tool.
*/
-import { Project, SyntaxKind, type Type, type Symbol as TsSymbol, type Node } from "ts-morph";
-import * as path from "path";
import * as fs from "fs";
+import * as path from "path";
+
+import { MCP_BLOCKED_TOOL_NAMES } from "../apps/erp/app/routes/api+/mcp+/lib/mcp-blocked-tools";
const ROOT = path.resolve(__dirname, "..");
-const MODULES_DIR = path.join(ROOT, "apps/erp/app/modules");
const MCP_LIB_DIR = path.join(ROOT, "apps/erp/app/routes/api+/mcp+/lib");
const TOOLS_DIR = path.join(MCP_LIB_DIR, "tools");
-const DOCS_PATH = path.join(ROOT, "llm/cache/mcp-tools-reference.md");
+const METADATA_FILE = path.join(MCP_LIB_DIR, "tool-metadata.json");
-// Parameters that should be auto-filled from McpContext
-const CONTEXT_PARAM_NAMES = ["companyId", "userId", "createdBy", "updatedBy"];
-const CONTEXT_PARAMS = new Set(CONTEXT_PARAM_NAMES);
-
-// Classify function by prefix
-function classifyFunction(name: string): "READ" | "WRITE" | "DESTRUCTIVE" {
- if (name.startsWith("delete")) return "DESTRUCTIVE";
- if (name.startsWith("get") || name.startsWith("list") || name.startsWith("fetch"))
- return "READ";
- return "WRITE";
-}
-
-function annotationConst(classification: "READ" | "WRITE" | "DESTRUCTIVE"): string {
- switch (classification) {
- case "READ":
- return "READ_ONLY_ANNOTATIONS";
- case "WRITE":
- return "WRITE_ANNOTATIONS";
- case "DESTRUCTIVE":
- return "DESTRUCTIVE_ANNOTATIONS";
- }
-}
-
-interface ParamInfo {
+interface ToolMetadata {
name: string;
- zodSchema: string;
- tsType: string;
- isContextParam: boolean;
- isOptional: boolean;
-}
-
-interface FunctionInfo {
- name: string;
- params: ParamInfo[];
+ module: string;
classification: "READ" | "WRITE" | "DESTRUCTIVE";
- /** Parameters that need validator imports from .models */
- validatorImports: Set<string>;
-}
-
-interface ModuleInfo {
- moduleName: string;
- servicePath: string;
- modelsPath: string | null;
- functions: FunctionInfo[];
- /** Maps validator name → import source path (resolved from the service file's imports) */
- validatorSources: Map<string, string>;
-}
-
-/**
- * Convert a source-level type annotation to a Zod schema string.
- * This works from the raw annotation text to avoid deep type resolution
- * that would expand z.infer<typeof X> into Zod's internal class hierarchy.
- */
-function annotationToZod(
- annotationText: string,
- resolvedType: Type,
- validatorImports: Set<string>
-): string {
- const text = annotationText.trim();
-
- // No annotation — fall back to resolved type for simple cases
- if (!text) {
- if (resolvedType.isString()) return "z.string()";
- if (resolvedType.isNumber()) return "z.number()";
- if (resolvedType.isBoolean()) return "z.boolean()";
- return "z.any()";
- }
-
- // Simple primitives
- if (text === "string") return "z.string()";
- if (text === "number") return "z.number()";
- if (text === "boolean") return "z.boolean()";
- if (text === "Json") return "z.any()";
-
- // z.infer<typeof xxxValidator> — reference the validator directly
- const inferMatch = text.match(/z\.infer<typeof\s+(\w+)>/);
- if (inferMatch) {
- validatorImports.add(inferMatch[1]);
- return `${inferMatch[1]}`;
- }
-
- // GenericQueryFilters (with or without intersection)
- if (text.includes("GenericQueryFilters")) {
- // Extract any additional properties from intersection: GenericQueryFilters & { search: string | null }
- const extraMatch = text.match(/GenericQueryFilters\s*&\s*\{([^}]*)\}/s);
- const baseParts = [
- " limit: z.number().int().default(100)",
- " offset: z.number().int().default(0)",
- ];
- if (extraMatch) {
- const extraProps = parseInlineObjectProps(extraMatch[1]);
- return `z.object({\n${[...baseParts, ...extraProps].join(",\n")}\n })`;
- }
- // Handle Omit<GenericQueryFilters, "..."> & { ... }
- if (text.includes("Omit<GenericQueryFilters")) {
- const omitMatch = text.match(/Omit<GenericQueryFilters,\s*["']([^"']+)["']>/);
- const omitKeys = omitMatch ? omitMatch[1].split("|").map(s => s.trim().replace(/['"]/g, "")) : [];
- const filteredParts = baseParts.filter(p => !omitKeys.some(k => p.includes(k)));
- const extraAfterOmit = text.match(/>\s*&\s*\{([^}]*)\}/s);
- const extraProps = extraAfterOmit ? parseInlineObjectProps(extraAfterOmit[1]) : [];
- return `z.object({\n${[...filteredParts, ...extraProps].join(",\n")}\n })`;
- }
- return `z.object({\n${baseParts.join(",\n")}\n })`;
- }
-
- // Nullable shorthand: string | null
- if (text.match(/^(\w+)\s*\|\s*null$/)) {
- const inner = text.replace(/\s*\|\s*null$/, "").trim();
- const innerZod = primitiveToZod(inner);
- return `${innerZod}.nullable()`;
- }
-
- // Union types involving validators or complex objects — use z.any()
- if (text.includes("|") && text.includes("z.infer")) {
- // Extract all validator names
- const validatorMatches = text.matchAll(/z\.infer<typeof\s+(\w+)>/g);
- for (const m of validatorMatches) {
- validatorImports.add(m[1]);
- }
- return "z.any()";
- }
-
- // Inline object type: { id: string; name: string; ... }
- if (text.startsWith("{")) {
- const inner = text.slice(1, -1);
- const props = parseInlineObjectProps(inner);
- return `z.object({\n${props.join(",\n")}\n })`;
- }
-
- // Array types
- if (text.endsWith("[]")) {
- const elementType = text.slice(0, -2);
- return `z.array(${primitiveToZod(elementType)})`;
- }
-
- // Complex union/intersection with Omit, z.infer, etc. — too complex for auto-gen
- if (text.includes("Omit<") || text.includes("z.infer<") || text.includes("&")) {
- // Extract all validator names for imports even if we use z.any()
- const validatorMatches = text.matchAll(/z\.infer<typeof\s+(\w+)>/g);
- for (const m of validatorMatches) {
- validatorImports.add(m[1]);
- }
- return "z.any()";
- }
-
- // String literal type
- if (text.startsWith('"') || text.startsWith("'")) return "z.string()";
-
- // Named types we don't know about — z.any()
- return "z.any()";
-}
-
-/**
- * Parse inline object properties from source text like "id: string; name: string | null"
- */
-function parseInlineObjectProps(propsText: string): string[] {
- const results: string[] = [];
- // Split on semicolons or newlines
- const parts = propsText.split(/[;\n]/).map(s => s.trim()).filter(Boolean);
- for (const part of parts) {
- const colonIndex = part.indexOf(":");
- if (colonIndex === -1) continue;
- let propName = part.slice(0, colonIndex).trim();
- const typeStr = part.slice(colonIndex + 1).trim();
-
- const isOptional = propName.endsWith("?");
- if (isOptional) propName = propName.slice(0, -1).trim();
-
- // Skip context params
- if (CONTEXT_PARAMS.has(propName)) continue;
-
- let zodType = primitiveToZod(typeStr);
- if (isOptional && !zodType.includes(".optional()")) {
- zodType += ".optional()";
- }
- results.push(` ${propName}: ${zodType}`);
- }
- return results;
-}
-
-/**
- * Convert a primitive-ish type string to Zod
- */
-function primitiveToZod(typeStr: string): string {
- const t = typeStr.trim();
- if (t === "string") return "z.string()";
- if (t === "number") return "z.number()";
- if (t === "boolean") return "z.boolean()";
- if (t === "Json") return "z.any()";
- if (t === "string | null") return "z.string().nullable()";
- if (t === "number | null") return "z.number().nullable()";
- if (t === "boolean | null") return "z.boolean().nullable()";
- if (t.endsWith("[]")) return `z.array(${primitiveToZod(t.slice(0, -2))})`;
- // String literal unions like "Draft" | "Active"
- if (t.includes('" | "') || t.includes("' | '")) {
- const values = t.split("|").map(s => s.trim().replace(/['"]/g, ""));
- return `z.enum([${values.map(v => `"${v}"`).join(", ")}])`;
- }
- return "z.any()";
-}
-
-/**
- * Safely get the type of a property symbol.
- * Falls back to z.any() representation for properties from mapped types,
- * Omit/Pick, or other type operations that lack value declarations.
- */
-function getPropertyType(prop: TsSymbol): Type | null {
- const decl = prop.getValueDeclaration();
- if (decl) return decl.getType();
-
- // Try declarations (plural) as fallback
- const decls = prop.getDeclarations();
- if (decls.length > 0) return decls[0].getType();
-
- return null;
-}
-
-/**
- * Convert a TypeScript type to a Zod schema string
- */
-function typeToZod(
- type: Type,
- validatorImports: Set<string>,
- depth: number = 0
-): string {
- if (depth > 5) return "z.any()";
-
- const typeText = type.getText();
-
- // Check for z.infer<typeof xxxValidator> pattern
- const inferMatch = typeText.match(
- /z\.infer<typeof\s+(\w+)>/
- );
- if (inferMatch) {
- validatorImports.add(inferMatch[1]);
- return `${inferMatch[1]}`;
- }
-
- // Primitives
- if (type.isString() || type.isStringLiteral()) return "z.string()";
- if (type.isNumber() || type.isNumberLiteral()) return "z.number()";
- if (type.isBoolean() || type.isBooleanLiteral()) return "z.boolean()";
-
- // null / undefined
- if (typeText === "null") return "z.null()";
- if (typeText === "undefined") return "z.undefined()";
-
- // Json type
- if (typeText === "Json") return "z.any()";
-
- // string literal unions
- if (type.isUnion()) {
- const unionTypes = type.getUnionTypes();
-
- // Check if it's a nullable type (T | null)
- const nonNullTypes = unionTypes.filter((t) => t.getText() !== "null");
- const hasNull = nonNullTypes.length < unionTypes.length;
- const nonUndefinedTypes = nonNullTypes.filter(
- (t) => t.getText() !== "undefined"
- );
- const hasUndefined = nonNullTypes.length > nonUndefinedTypes.length;
-
- if (nonUndefinedTypes.length === 1 && (hasNull || hasUndefined)) {
- const inner = typeToZod(nonUndefinedTypes[0], validatorImports, depth + 1);
- if (hasNull && hasUndefined) return `${inner}.nullable().optional()`;
- if (hasNull) return `${inner}.nullable()`;
- return `${inner}.optional()`;
- }
-
- // String literal union → z.enum
- if (unionTypes.every((t) => t.isStringLiteral())) {
- const values = unionTypes.map((t) =>
- t.getText().replace(/^"/, "").replace(/"$/, "")
- );
- return `z.enum([${values.map((v) => `"${v}"`).join(", ")}])`;
- }
-
- // Generic union → z.union
- if (nonUndefinedTypes.length > 1) {
- const schemas = nonUndefinedTypes.map((t) =>
- typeToZod(t, validatorImports, depth + 1)
- );
- return `z.union([${schemas.join(", ")}])`;
- }
- }
-
- // Arrays
- if (type.isArray()) {
- const elementType = type.getArrayElementTypeOrThrow();
- return `z.array(${typeToZod(elementType, validatorImports, depth + 1)})`;
- }
-
- // Object types (interfaces, type literals)
- if (type.isObject() && !type.isArray()) {
- const properties = type.getProperties();
- if (properties.length === 0) return "z.object({})";
-
- // Check for index signatures (Record types)
- const stringIndex = type.getStringIndexType();
- if (stringIndex) {
- return `z.record(z.string(), ${typeToZod(stringIndex, validatorImports, depth + 1)})`;
- }
-
- const props = properties
- .map((prop) => {
- const propName = prop.getName();
- const propType = getPropertyType(prop);
- if (!propType) return ` ${propName}: z.any()`;
- const isOptional = prop.isOptional();
- let zodType = typeToZod(propType, validatorImports, depth + 1);
- if (isOptional && !zodType.includes(".optional()")) {
- zodType += ".optional()";
- }
- return ` ${propName}: ${zodType}`;
- })
- .join(",\n");
-
- return `z.object({\n${props}\n })`;
- }
-
- // Intersection types - merge properties
- if (type.isIntersection()) {
- const intersectionTypes = type.getIntersectionTypes();
- const allProps: string[] = [];
-
- for (const t of intersectionTypes) {
- const zodStr = typeToZod(t, validatorImports, depth + 1);
- // If it resolves to a z.object, extract its properties
- if (zodStr.startsWith("z.object(")) {
- // We'll just use .merge pattern
- allProps.push(zodStr);
- } else {
- // It's a named validator or other type
- allProps.push(zodStr);
- }
- }
-
- if (allProps.length === 1) return allProps[0];
- // For intersections, use the first and merge the rest
- return allProps.reduce((acc, curr) => {
- if (acc.startsWith("z.object(") && curr.startsWith("z.object(")) {
- return `${acc}.merge(${curr})`;
- }
- return `${acc}.and(${curr})`;
+ description: string;
+ paramCount: number;
+}
+
+// Parse a tool file to extract metadata
+function extractToolsFromFile(filePath: string, moduleName: string): ToolMetadata[] {
+ const content = fs.readFileSync(filePath, 'utf-8');
+ const tools: ToolMetadata[] = [];
+
+ // Regular expression to match tool registrations (matches until annotations)
+ const toolRegex = /server\.registerTool\(\s*"([^"]+)",\s*\{([\s\S]*?)annotations:\s*(\w+_ANNOTATIONS)/g;
+ let match;
+
+ while ((match = toolRegex.exec(content)) !== null) {
+ const toolName = match[1];
+ const configBlock = match[2];
+ const annotationType = match[3];
+
+ // Extract description
+ const descMatch = configBlock.match(/description:\s*"([^"]+)"/);
+ const description = descMatch ? descMatch[1] : toolName;
+
+ // Determine classification from annotations
+ let classification: "READ" | "WRITE" | "DESTRUCTIVE" = "WRITE";
+ if (annotationType === "DESTRUCTIVE_ANNOTATIONS") {
+ classification = "DESTRUCTIVE";
+ } else if (annotationType === "READ_ONLY_ANNOTATIONS") {
+ classification = "READ";
+ }
+
+ // Count parameters (simplified - counts properties in inputSchema)
+ const inputSchemaMatch = configBlock.match(/inputSchema:\s*z\.object\(\{([^}]*)\}\)/);
+ let paramCount = 0;
+ if (inputSchemaMatch) {
+ const schemaContent = inputSchemaMatch[1];
+ // Count occurrences of property definitions (simplified)
+ const propMatches = schemaContent.match(/\w+:\s*z\./g);
+ paramCount = propMatches ? propMatches.length : 0;
+ }
+
+ tools.push({
+ name: toolName,
+ module: moduleName,
+ classification,
+ description,
+ paramCount
});
}
-
- // Fallback
- return "z.any()";
-}
-
-/**
- * Extract function info and validator import sources from a service file
- */
-function extractFunctions(
- project: Project,
- filePath: string,
- moduleName: string
-): { functions: FunctionInfo[]; validatorSources: Map<string, string> } {
- const sourceFile = project.addSourceFileAtPath(filePath);
-
- // Build a map of imported names → their source module path
- // This lets us know where validators are actually imported from
- const validatorSources = new Map<string, string>();
- for (const imp of sourceFile.getImportDeclarations()) {
- const moduleSpecifier = imp.getModuleSpecifierValue();
- for (const named of imp.getNamedImports()) {
- const name = named.getName();
- if (name.endsWith("Validator") || name.endsWith("Type") || name.endsWith("type")) {
- validatorSources.set(name, moduleSpecifier);
- }
- }
- }
- const functions: FunctionInfo[] = [];
-
- for (const fn of sourceFile.getFunctions()) {
- if (!fn.isExported()) continue;
- if (!fn.isAsync()) continue;
-
- const name = fn.getName();
- if (!name) continue;
-
- const classification = classifyFunction(name);
- const validatorImports = new Set<string>();
- const params: ParamInfo[] = [];
-
- const fnParams = fn.getParameters();
-
- for (let i = 0; i < fnParams.length; i++) {
- const param = fnParams[i];
- let paramName = param.getName();
- const paramType = param.getType();
-
- // Get the source-level type annotation text (before TS resolves it)
- const typeNode = param.getTypeNode();
- const annotationText = typeNode?.getText() ?? "";
- const resolvedText = paramType.getText();
-
- // Skip the first parameter if it's a SupabaseClient
- if (i === 0 && (annotationText.includes("SupabaseClient") || resolvedText.includes("SupabaseClient"))) continue;
-
- // Handle destructured parameters — give them a synthetic name
- const isDestructured = paramName.startsWith("{") || paramName.startsWith("[");
- if (isDestructured) {
- paramName = `arg${i}`;
- }
-
- const isContextParam = CONTEXT_PARAMS.has(paramName);
- const isOptional = param.isOptional() || param.hasInitializer();
-
- let zodSchema: string;
-
- // Use annotation text to detect patterns BEFORE deep type resolution
- zodSchema = annotationToZod(annotationText, paramType, validatorImports);
-
- params.push({
- name: paramName,
- zodSchema,
- tsType: annotationText || resolvedText,
- isContextParam,
- isOptional,
- });
- }
-
- functions.push({ name, params, classification, validatorImports });
- }
-
- return { functions, validatorSources };
-}
-
-/**
- * Generate tool file content for a module
- */
-function generateToolFile(module: ModuleInfo): string {
- const { moduleName, functions } = module;
- const registerName = `register${capitalize(moduleName)}Tools`;
-
- // Collect all validator imports needed
- const allValidatorImports = new Set<string>();
- for (const fn of functions) {
- for (const v of fn.validatorImports) {
- allValidatorImports.add(v);
- }
- }
-
- // Collect all function imports
- const fnNames = functions.map((f) => f.name);
-
- let imports = `import { z } from "zod";
-import type { RegisterTools } from "../types";
-import {
- READ_ONLY_ANNOTATIONS,
- WRITE_ANNOTATIONS,
- DESTRUCTIVE_ANNOTATIONS,
- toMcpResult,
- withErrorHandling,
-} from "../types";
-import {
-${fnNames.map((n) => ` ${n},`).join("\n")}
-} from "~/modules/${moduleName}/${moduleName}.service";`;
-
- // Group validator imports by their actual source module
- if (allValidatorImports.size > 0) {
- const importsBySource = new Map<string, string[]>();
- for (const v of allValidatorImports) {
- const source = module.validatorSources.get(v);
- // Resolve the import path: use the original source if available,
- // otherwise fall back to the module's own models file
- let importPath: string;
- if (source) {
- // Convert relative paths from the service file to be relative to mcp/tools/
- // Service files are at ~/modules/{mod}/{mod}.service.ts
- // Tool files are at ~/modules/mcp/tools/{mod}.ts
- // So "../shared" from items.service.ts → "~/modules/shared"
- if (source.startsWith("../")) {
- importPath = `~/modules/${source.slice(3)}`;
- } else if (source.startsWith("./")) {
- importPath = `~/modules/${moduleName}/${source.slice(2)}`;
- } else if (source.startsWith("~/")) {
- importPath = source;
- } else {
- // External package — use as-is
- importPath = source;
- }
- } else if (module.modelsPath) {
- importPath = `~/modules/${moduleName}/${moduleName}.models`;
- } else {
- continue; // Skip if no source found and no models file
- }
- if (!importsBySource.has(importPath)) {
- importsBySource.set(importPath, []);
- }
- importsBySource.get(importPath)!.push(v);
- }
-
- for (const [importPath, names] of importsBySource) {
- imports += `\nimport {
-${names.map((n) => ` ${n},`).join("\n")}
-} from "${importPath}";`;
- }
- }
-
- const toolRegistrations = functions
- .map((fn) => generateToolRegistration(moduleName, fn))
- .join("\n\n");
-
- return `// @ts-nocheck
-// AUTO-GENERATED by scripts/generate-mcp.ts — do not edit manually
-${imports}
-
-export const ${registerName}: RegisterTools = (server, ctx) => {
-${toolRegistrations}
-};
-`;
-}
-
-/**
- * Generate a single tool registration
- */
-function generateToolRegistration(moduleName: string, fn: FunctionInfo): string {
- const toolName = `${moduleName}_${fn.name}`;
- const annotation = annotationConst(fn.classification);
-
- // Build the input schema
- const inputSchemaEntries: string[] = [];
- const callArgs: string[] = ["ctx.client"];
-
- for (const param of fn.params) {
- if (param.isContextParam) {
- // Auto-fill from context
- if (param.name === "companyId") callArgs.push("ctx.companyId");
- else if (param.name === "userId") callArgs.push("ctx.userId");
- else if (param.name === "createdBy") callArgs.push("ctx.userId");
- else if (param.name === "updatedBy") callArgs.push("ctx.userId");
- continue;
- }
-
- // For object params that have context fields filtered out, we need special handling
- if (param.zodSchema.startsWith("z.object(")) {
- inputSchemaEntries.push(
- ` ${param.name}: ${param.zodSchema}${param.isOptional ? ".optional()" : ""}`
- );
- callArgs.push(`params.${param.name}`);
- } else {
- inputSchemaEntries.push(
- ` ${param.name}: ${param.zodSchema}${param.isOptional ? ".optional()" : ""}`
- );
- callArgs.push(`params.${param.name}`);
- }
- }
-
- // If there are no visible params, check if we only had context params
- // In that case, we still need to pass them through
- const hasVisibleParams = fn.params.some((p) => !p.isContextParam);
-
- // Build the handler
- const inputSchema =
- inputSchemaEntries.length > 0
- ? `{\n${inputSchemaEntries.join(",\n")},\n }`
- : "{}";
-
- // Check if context params are embedded INSIDE an object parameter's type
- // (e.g., `payload: { id, companyId, userId }`) vs being separate positional params
- // (e.g., `(client, companyId, args)`). Only merge when context is inside the object.
- const objectParamsWithEmbeddedContext = fn.params.filter(
- (p) =>
- !p.isContextParam &&
- CONTEXT_PARAM_NAMES.some((cp) => p.tsType.includes(cp))
- );
-
- let handlerBody: string;
-
- if (objectParamsWithEmbeddedContext.length > 0) {
- // Context params live inside the object param — merge them in
- const objectParam = objectParamsWithEmbeddedContext[0];
-
- // Detect which context fields appear in the type annotation
- const embeddedContextFields: string[] = [];
- for (const cp of CONTEXT_PARAM_NAMES) {
- // Check for the field name in the type annotation (as a property, not substring)
- if (new RegExp(`\\b${cp}\\b`).test(objectParam.tsType)) {
- if (cp === "createdBy" || cp === "updatedBy") {
- embeddedContextFields.push(`${cp}: ctx.userId`);
- } else {
- embeddedContextFields.push(`${cp}: ctx.${cp}`);
- }
- }
- }
-
- // Also include any separate context params from callArgs
- const separateContextAssignments = fn.params
- .filter((p) => p.isContextParam)
- .map((p) => {
- if (p.name === "createdBy" || p.name === "updatedBy")
- return `${p.name}: ctx.userId`;
- return `${p.name}: ctx.${p.name}`;
- });
-
- const allContextAssignments = [
- ...new Set([...embeddedContextFields, ...separateContextAssignments]),
- ].join(", ");
-
- // Build call args, replacing the object param with the merged version
- const mergedCallArgs = callArgs.map((arg) =>
- arg === `params.${objectParam.name}`
- ? `{ ...params.${objectParam.name}, ${allContextAssignments} }`
- : arg
- );
-
- handlerBody = ` const result = await ${fn.name}(${mergedCallArgs.join(", ")});
- return toMcpResult(result);`;
- } else {
- handlerBody = ` const result = await ${fn.name}(${callArgs.join(", ")});
- return toMcpResult(result);`;
- }
-
- // Build description from function name
- const description = humanizeFunction(fn.name, moduleName);
-
- return ` server.registerTool(
- "${toolName}",
- {
- description: "${description}",
- inputSchema: ${inputSchema},
- annotations: ${annotation},
- },
- withErrorHandling(async (params) => {
-${handlerBody}
- }, "Failed: ${toolName}"),
- );`;
-}
-
-function humanizeFunction(name: string, moduleName: string): string {
- // Split camelCase
- const words = name
- .replace(/([A-Z])/g, " $1")
- .toLowerCase()
- .trim()
- .split(" ");
- return words.join(" ");
-}
-
-function capitalize(s: string): string {
- return s.charAt(0).toUpperCase() + s.slice(1);
-}
-
-/**
- * Generate the barrel export (index.ts)
- */
-function generateBarrelExport(modules: ModuleInfo[]): string {
- const imports = modules
- .map(
- (m) =>
- `export { register${capitalize(m.moduleName)}Tools } from "./${m.moduleName}";`
- )
- .join("\n");
-
- return `// @ts-nocheck
-// AUTO-GENERATED by scripts/generate-mcp.ts — do not edit manually
-${imports}
-`;
-}
-
-/**
- * Generate the server.ts file
- */
-function generateServerFile(modules: ModuleInfo[]): string {
- const imports = modules
- .map(
- (m) =>
- ` register${capitalize(m.moduleName)}Tools,`
- )
- .join("\n");
-
- const registrations = modules
- .map(
- (m) =>
- ` register${capitalize(m.moduleName)}Tools(server, ctx);`
- )
- .join("\n");
-
- const moduleDescriptions = modules
- .map((m) => {
- const readCount = m.functions.filter(
- (f) => f.classification === "READ"
- ).length;
- const writeCount = m.functions.filter(
- (f) => f.classification === "WRITE"
- ).length;
- const deleteCount = m.functions.filter(
- (f) => f.classification === "DESTRUCTIVE"
- ).length;
- return `- ${m.moduleName}_* — ${readCount} read, ${writeCount} write, ${deleteCount} delete tools`;
- })
- .join("\n");
-
- return `// @ts-nocheck
-// AUTO-GENERATED by scripts/generate-mcp.ts — do not edit manually
-import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
-import type { McpContext } from "./types";
-import {
-${imports}
-} from "./tools";
-
-function getServerInstructions(): string {
- const today = new Date().toISOString().split("T")[0];
-
- return \`Carbon ERP is a manufacturing system. This MCP server provides access to ERP data including sales, purchasing, inventory, production, quality, and more.
-
-## Current Date
-Today is \${today}.
-
-## Tool Organization
-Tools are namespaced by module — use the prefix to discover related tools:
-${moduleDescriptions}
-
-## Key Patterns
-- All monetary amounts use the company's base currency unless specified.
-- Date parameters use ISO 8601 format (YYYY-MM-DD).
-- List tools support pagination via limit/offset (GenericQueryFilters).
-- companyId and userId are auto-filled from the authenticated context — do not provide them.
-- Most get/list tools return { data, error, count? } — check error before using data.
-- Tool errors return isError: true with a text explanation.
-\`;
-}
-
-export function createMcpServer(ctx: McpContext): McpServer {
- const server = new McpServer(
- {
- name: "carbon-erp",
- version: process.env.VERCEL_GIT_COMMIT_SHA?.slice(0, 7) ?? "1.0.0",
- },
- {
- instructions: getServerInstructions(),
- },
- );
-
-${registrations}
-
- return server;
-}
-`;
-}
-
-/**
- * Generate documentation
- */
-function generateDocs(modules: ModuleInfo[]): string {
- let totalTools = 0;
- const sections: string[] = [];
-
- for (const module of modules) {
- totalTools += module.functions.length;
- const lines: string[] = [
- `## ${module.moduleName} (${module.functions.length} tools)`,
- "",
- ];
-
- for (const fn of module.functions) {
- lines.push(
- `### ${module.moduleName}_${fn.name} (${fn.classification})`
- );
- lines.push(humanizeFunction(fn.name, module.moduleName));
-
- const visibleParams = fn.params.filter((p) => !p.isContextParam);
- if (visibleParams.length > 0) {
- lines.push("**Parameters:**");
- for (const param of visibleParams) {
- const opt = param.isOptional ? " (optional)" : "";
- lines.push(`- \`${param.name}\`: ${param.tsType}${opt}`);
- }
- } else {
- lines.push("**Parameters:** none (context auto-filled)");
- }
- lines.push("");
- }
-
- sections.push(lines.join("\n"));
- }
-
- return `# Carbon ERP MCP Tools Reference
-
-> Auto-generated by scripts/generate-mcp.ts
-> Total: ${totalTools} tools across ${modules.length} modules
-
-${sections.join("\n---\n\n")}`;
-}
-
-// ─── Main ──────────────────────────────────────────────────────────────
-
-async function main() {
- console.log("Initializing TypeScript project...");
-
- const project = new Project({
- tsConfigFilePath: path.join(ROOT, "apps/erp/tsconfig.json"),
- skipAddingFilesFromTsConfig: true,
- });
-
- // Find all service files
- const serviceFiles = fs
- .readdirSync(MODULES_DIR, { withFileTypes: true })
- .filter((d) => d.isDirectory())
- .map((d) => ({
- moduleName: d.name,
- servicePath: path.join(MODULES_DIR, d.name, `${d.name}.service.ts`),
- modelsPath: fs.existsSync(
- path.join(MODULES_DIR, d.name, `${d.name}.models.ts`)
- )
- ? path.join(MODULES_DIR, d.name, `${d.name}.models.ts`)
- : null,
- }))
- .filter((m) => {
- if (!fs.existsSync(m.servicePath)) {
- console.log(` Skipping ${m.moduleName}: no service file`);
- return false;
- }
- // Skip the mcp module itself
- if (m.moduleName === "mcp") return false;
- return true;
- });
-
- console.log(`Found ${serviceFiles.length} service modules`);
-
- const modules: ModuleInfo[] = [];
-
- for (const sf of serviceFiles) {
- console.log(` Parsing ${sf.moduleName}...`);
+
+ return tools;
+}
+
+export function generateToolMetadata(): void {
+ console.log("Generating tool metadata for JIT loading...");
+
+ const allTools: ToolMetadata[] = [];
+
+ // Get all tool files
+ const toolFiles = fs.readdirSync(TOOLS_DIR)
+ .filter(f => f.endsWith('.ts') && f !== 'index.ts')
+ .map(f => ({
+ path: path.join(TOOLS_DIR, f),
+ module: f.replace('.ts', '')
+ }));
+
+ for (const file of toolFiles) {
try {
- const { functions, validatorSources } = extractFunctions(project, sf.servicePath, sf.moduleName);
- console.log(` → ${functions.length} exported functions`);
-
- modules.push({
- moduleName: sf.moduleName,
- servicePath: sf.servicePath,
- modelsPath: sf.modelsPath,
- functions,
- validatorSources,
- });
- } catch (err) {
- console.error(` ✗ Error parsing ${sf.moduleName}:`, err);
- }
- }
-
- // Ensure output directory exists
- fs.mkdirSync(TOOLS_DIR, { recursive: true });
-
- // Generate tool files
- console.log("\nGenerating tool files...");
- for (const module of modules) {
- if (module.functions.length === 0) {
- console.log(` Skipping ${module.moduleName}: no functions`);
- continue;
- }
-
- const content = generateToolFile(module);
- const outPath = path.join(TOOLS_DIR, `${module.moduleName}.ts`);
- fs.writeFileSync(outPath, content);
- console.log(` ✓ ${module.moduleName}.ts (${module.functions.length} tools)`);
- }
-
- // Generate barrel export
- const barrelContent = generateBarrelExport(
- modules.filter((m) => m.functions.length > 0)
- );
- fs.writeFileSync(path.join(TOOLS_DIR, "index.ts"), barrelContent);
- console.log(" ✓ index.ts (barrel export)");
-
- // Generate server.ts
- const serverContent = generateServerFile(
- modules.filter((m) => m.functions.length > 0)
- );
- fs.writeFileSync(path.join(MCP_LIB_DIR, "server.ts"), serverContent);
- console.log(" ✓ server.ts");
-
- // Generate docs
- console.log("\nGenerating documentation...");
- fs.mkdirSync(path.dirname(DOCS_PATH), { recursive: true });
- const docs = generateDocs(modules.filter((m) => m.functions.length > 0));
- fs.writeFileSync(DOCS_PATH, docs);
- console.log(` ✓ ${path.relative(ROOT, DOCS_PATH)}`);
-
- const totalTools = modules.reduce((sum, m) => sum + m.functions.length, 0);
- console.log(`\nDone! Generated ${totalTools} tools across ${modules.length} modules.`);
-}
-
-main().catch((err) => {
- console.error("Fatal error:", err);
- process.exit(1);
-});
+ const tools = extractToolsFromFile(file.path, file.module).filter(
+ (t) => !MCP_BLOCKED_TOOL_NAMES.includes(t.name),
+ );
+ allTools.push(...tools);
+ console.log(` ✓ ${file.module}: ${tools.length} tools`);
+ } catch (error) {
+ console.error(` ✗ Failed to process ${file.module}:`, error);
+ }
+ }
+
+ // Write metadata file
+ const metadata = {
+ generated: new Date().toISOString(),
+ totalTools: allTools.length,
+ modules: [...new Set(allTools.map(t => t.module))].length,
+ tools: allTools
+ };
+
+ fs.writeFileSync(METADATA_FILE, JSON.stringify(metadata, null, 2));
+ console.log(`\n✓ Generated metadata for ${allTools.length} tools`);
+ console.log(` Output: ${path.relative(ROOT, METADATA_FILE)}`);
+}
+
+// Run if called directly
+if (require.main === module) {
+ generateToolMetadata();
+}
\ No newline at end of file