d365-mcp-server
v1.0.4
Published
MCP server for D365 Sales Accelerator — 48 tools for recommendations, opportunities, milestones, BPF, Power BI ACR, Customer360, schema introspection, and contacts/competitors
Maintainers
Readme
d365-mcp-server
Local stdio MCP server for Dynamics 365 Sales Accelerator, Power BI ACR, Customer360, and related seller workflows.
This package is meant to be downloaded by MCP clients such as VS Code and then used as a local command-line MCP server.
Repository context
- Private source repo:
BifrostOps - Public install hub:
BifrostOps-install
This README is the package-level technical reference. End-user onboarding lives in the public install repo, while implementation and contribution workflow live in the private source repo.
Requirements
- Node.js 20+
- Access to your target Dynamics 365 organization
- An MCP client that can launch stdio servers (for example, VS Code)
Install
Run directly with npx
This is the easiest zero-install path for users:
npx -y d365-mcp-server --helpnpx -y d365-mcp-server --print-vscode-config
Install globally
If you want a stable local command:
npm install -g d365-mcp-serverd365-mcp-server --help
miniFrost agent
This package also ships the miniFrost custom agent and automatically installs or refreshes it in the global Copilot profile folder:
~/.copilot/agents/miniFrost.agent.md
That makes miniFrost available in the Copilot agent picker for the user.
If you ever need to repair the installation manually:
d365-mcp-server --install-agentd365-mcp-server --print-agent-path
Important: keep your MCP server id as d365-mcp-server in mcp.json. The packaged miniFrost agent is wired to tools: ["d365-mcp-server/*"], so renaming the server entry breaks agent-to-tool binding.
Configure in VS Code
Generate a ready-to-paste MCP snippet:
npx -y d365-mcp-server --print-vscode-config
Example mcp.json snippet:
{
"servers": {
"d365-mcp-server": {
"type": "stdio",
"command": "npx",
"args": ["-y", "d365-mcp-server"],
"env": {
"D365_AUTH_MODE": "auto",
"D365_ORG_URL": "https://your-org.crm.dynamics.com"
}
}
}
}If your MCP client supports cwd, point it to the folder containing your .env file. The server looks for .env in the current working directory first, then falls back to package/repo-style layouts.
Use the server key exactly as shown above: d365-mcp-server.
Global-install variant
If you installed the package globally, you can use:
{
"servers": {
"d365-mcp-server": {
"type": "stdio",
"command": "d365-mcp-server",
"env": {
"D365_AUTH_MODE": "auto",
"D365_ORG_URL": "https://your-org.crm.dynamics.com"
}
}
}
}Environment variables
Common settings:
D365_ORG_URL=https://your-org.crm.dynamics.com
D365_AUTH_MODE=auto
# D365_DEBUG=1
# D365_WAM_ENABLED=false
# PBI_MODEL_OBJECT_ID=
# PBI_TIMEOUT_MS=90000Auth modes
auto— tries silent cache/WAM first, then browser popup fallbackinteractive— forces browser popup immediatelydevice_code— terminal-based device code flow for headless or SSH sessions
On Windows, auto can use WAM (Web Account Manager) when @azure/msal-node-extensions is available. Disable it with D365_WAM_ENABLED=false if needed.
Use it
Once the MCP server is configured and connected, ask your client things like:
- “Show my open recommendations”
- “What stage is opportunity 7-... at?”
- “Show milestones for Contoso”
- “How much Azure ACR does this account have?”
CLI helpers
d365-mcp-server --help— usage, env vars, and quick startd365-mcp-server --version— package versiond365-mcp-server --install-agent— install or refresh the globalminiFrostagentd365-mcp-server --print-agent-path— show where the global agent file should lived365-mcp-server --print-vscode-config— ready-to-paste VS Code MCP config
Running d365-mcp-server with no flags starts the stdio MCP server and should normally be done by an MCP client, not by hand in a regular terminal.
For maintainers
Build and preview the published package:
npm run buildnpm testnpm run pack:dry-run
The build copies the shared runtime libraries into dist/vendor/scripts/lib so the published npm package works outside the monorepo/repo layout.
The build also copies .github/agents/*.agent.md into dist/agents so packaged installs can seed the user's global Copilot agents directory.
