home / mcp / microsoft business central mcp server
Provides MCP-based access to Business Central data with full CRUD and Azure CLI authentication.
Configuration
View docs{
"mcpServers": {
"knowall-ai-mcp-business-central": {
"command": "cmd",
"args": [
"/c",
"npx",
"-y",
"@knowall-ai/mcp-business-central"
],
"env": {
"BC_COMPANY": "Your Company Name",
"BC_AUTH_TYPE": "azure_cli",
"BC_URL_SERVER": "https://api.businesscentral.dynamics.com/v2.0/{tenant-id}/{environment}/api/v2.0"
}
}
}
}You are building an MCP Server for Microsoft Dynamics 365 Business Central. This server enables AI assistants to query and modify Business Central data through properly structured API calls, with zero installation required when using npx. It supports full CRUD operations and leverages Azure CLI authentication for secure access.
To use this MCP server with your MCP client, configure the client to connect via a local stdio channel. The server provides a set of tools to explore and manipulate Business Central data, including querying metadata, listing records with optional filters, creating new records, updating existing ones, and deleting entries. You can perform common data operations such as fetching customer details, creating new contacts, updating company information, and deleting records as needed. Ensure your client passes the appropriate resource name (for example, customers, contacts, or salesOrders) and, when required, the item data or identifiers to identify specific records.
Prerequisites: you need Node.js installed and access to the Azure CLI for authentication. You will run a pre-packaged MCP server that works without a local install, via npx, or you can run through an onboarding flow supported by Smithery.
Recommended path: run directly with npx from a client like Claude Desktop or Claude Code using the provided MCP configuration.
Environment variables you use to configure the server are passed to the MCP runtime. The essential variables are: - BC_URL_SERVER: the Business Central API base URL - BC_COMPANY: the Company display name - BC_AUTH_TYPE: authentication type (default: azure_cli) Use Azure CLI to authenticate and obtain a token for Business Central API access.
401 Unauthorized: ensure you are logged in through Azure CLI (az login) and that you have access to the Business Central tenant. Retrieve a token with az account get-access-token --resource https://api.businesscentral.dynamics.com. If a specific company is not found, verify the company name matches exactly and that the tenant URL includes the correct tenantId and environment.
You can run the MCP server without installing dependencies by using npx. There is also an option to install and run via Smithery for on-boarding. The stdio configuration uses a Windows-friendly command that runs npx with the package name to start the server.
If you prefer to develop locally, clone the project, install dependencies, and build the project. Then start the server via the provided runtime. This path is optional if you simply want to run the MCP in a zero-install setup.
Fetch OData metadata for a specified Business Central resource such as customers, contacts, or salesOpportunities.
List items from a resource with optional filtering and pagination using OData expressions.
Retrieve items that match a specific field value on a given resource.
Create a new record in a specified Business Central resource using the provided data.
Update fields of an existing item identified by its ID within a resource.
Delete an item from a specified resource by its ID.