bc-webclient-mcp
Version:
Model Context Protocol (MCP) server for Microsoft Dynamics 365 Business Central via WebUI protocol. Enables AI assistants to interact with BC through the web client protocol, supporting Card, List, and Document pages with full line item support and server
56 lines • 2.11 kB
TypeScript
/**
* Start Workflow Tool
*
* Creates a new workflow context for tracking multi-step business processes.
* Use this at the beginning of complex BC workflows to maintain state across operations.
*/
import type { Result } from '../core/result.js';
import type { BCError } from '../core/errors.js';
import { BaseMCPTool } from './base-tool.js';
/**
* Input schema for start_workflow tool.
*/
export interface StartWorkflowInput {
readonly goal: string;
readonly parameters?: Record<string, unknown>;
readonly sessionId?: string;
}
/**
* StartWorkflowTool creates a new workflow context.
*
* Workflows track:
* - Goal and input parameters
* - Current page and record position
* - Operation history (all tool calls)
* - Pending changes and errors
*
* Example goals:
* - "create_sales_invoice"
* - "post_sales_order"
* - "update_customer_credit_limit"
*/
export declare class StartWorkflowTool extends BaseMCPTool {
readonly name = "start_workflow";
readonly description = "Start a new workflow to track a multi-step business process. Returns a workflowId for state tracking across operations.";
readonly inputSchema: {
readonly type: "object";
readonly properties: {
readonly goal: {
readonly type: "string";
readonly description: "Description of the workflow goal (e.g., \"create_sales_invoice\", \"post_sales_order\")";
};
readonly parameters: {
readonly type: "object";
readonly description: "Optional workflow parameters (inputs like customer number, amounts, dates)";
readonly additionalProperties: true;
};
readonly sessionId: {
readonly type: "string";
readonly description: "Optional BC session ID to link workflow to. If not provided, creates a new session.";
};
};
readonly required: readonly ["goal"];
};
protected executeInternal(input: unknown): Promise<Result<unknown, BCError>>;
}
//# sourceMappingURL=start-workflow-tool.d.ts.map