1. Conduid
  2. Science
  3. Commerce Csharp
MCP server · Science

Commerce Csharp

Remote Model Context Protocol (MCP) server for Microsoft Dynamics 365 Commerce - HTTP/HTTPS transport with comprehensive D365 Commerce APIs

Unclaimed science
34Low

Scored 6 months ago · breakdown

About Commerce Csharp

Commerce Csharp is an MCP server in the Science category: remote Model Context Protocol (MCP) server for Microsoft Dynamics 365 Commerce - HTTP/HTTPS transport with comprehensive D365 Commerce APIs.

Install

From source
git clone https://github.com/jiantmo/mcp-commerce-csharp

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Ask AI

✦

Ask AI about Commerce Csharp

Powered by Claude · Grounded in docs

I know everything about Commerce Csharp. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ✓README presentThe repository ships documentation.

5 checks have not been run yet.

README

D365 Commerce MCP Server

A C# based Model Context Protocol (MCP) server for Microsoft Dynamics 365 Commerce. This server provides tools for interacting with D365 Commerce customer data through the MCP protocol.

Features

  • Customer Search Tool: Search for customers using various criteria including account number, email, phone, or general search text
  • MCP Protocol Compliance: Fully implements the MCP 2025-06-18 specification
  • Structured Logging: Built-in logging for debugging and monitoring (writes to stderr to avoid corrupting JSON-RPC messages)
  • Extensible Architecture: Easy to add new tools and controllers
  • Proper Error Handling: Comprehensive error handling for both protocol and tool execution errors

Tools Available

customer_search

Searches for customers in D365 Commerce based on provided search criteria.

Parameters:

  • customerSearchCriteria (required): Object containing search parameters
    • searchText (optional): General search text to find customers
    • accountNumber (optional): Customer account number
    • email (optional): Customer email address
    • phone (optional): Customer phone number
    • extensionProperties (optional): Array of additional properties
  • queryResultSettings (optional): Paging and sorting settings
    • paging: Object with skip (0-∞) and top (1-1000) properties
    • sorting: Object with field and isDescending properties

Returns: PageResult containing matching GlobalCustomer records with properties like:

  • PartyNumber
  • RecordId
  • AccountNumber
  • FullName
  • FullAddress
  • Phone
  • Email
  • CustomerTypeValue
  • And more...

Project Structure

McpCommerceServer/
├── Controllers/
│   └── CustomerController.cs      # Customer-related operations
├── Models/
│   └── CustomerDataModels.cs     # D365 Commerce customer data models
├── Mcp/
│   └── McpModels.cs              # MCP protocol models
├── Services/
│   └── McpServer.cs              # Main MCP server implementation
├── Program.cs                     # Application entry point
└── McpCommerceServer.csproj      # Project file

MCP Compliance

This server implements the MCP 2025-06-18 specification with:

  • ✅ Protocol Version: 2025-06-18
  • ✅ Initialization Flow: Proper initialize → initialized notification sequence
  • ✅ Tool Capabilities: Declares tools capability with listChanged support
  • ✅ JSON-RPC 2.0: Compliant message format
  • ✅ Structured Tool Definitions: Includes name, title, description, and detailed inputSchema
  • ✅ Error Handling: Both protocol errors and tool execution errors
  • ✅ Logging Safety: Writes only to stderr to avoid corrupting STDIO transport

Getting Started

Prerequisites

  • .NET 8.0 SDK
  • Visual Studio Code or Visual Studio

Building the Project

dotnet build McpCommerceServer.csproj

Running the Server

dotnet run --project McpCommerceServer.csproj

The server will start and listen for MCP protocol messages on standard input/output.

Publishing

dotnet publish McpCommerceServer.csproj -c Release -o ./publish --self-contained false

Implementation Status

  • ✅ Basic MCP server infrastructure
  • ✅ Customer search tool structure
  • ⚠️ Customer search logic (placeholder implementation)
  • ❌ D365 Commerce API integration
  • ❌ Authentication and authorization
  • ❌ Additional customer tools (CreateEntity, UpdateEntity, etc.)

Next Steps

  1. Implement D365 Commerce Integration: Add actual API calls to D365 Commerce services
  2. Add Authentication: Implement proper authentication for D365 Commerce
  3. Expand Customer Tools: Add the remaining customer controller methods
  4. Error Handling: Enhance error handling and validation
  5. Testing: Add unit and integration tests
  6. Configuration: Add configuration management for connection strings and settings

Configuration

The application uses .NET's built-in configuration system. You can add configuration through:

  • appsettings.json
  • Environment variables
  • Command line arguments

Example configuration structure:

{
  "D365Commerce": {
    "BaseUrl": "https://your-d365-commerce-instance.com",
    "ClientId": "your-client-id",
    "ClientSecret": "your-client-secret",
    "TenantId": "your-tenant-id"
  }
}

License

This project is licensed under the MIT License.

README copy captured when this server was indexed; it may lag the repository. The original is authoritative.

Questions

About Commerce Csharp

How do I install Commerce Csharp?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is Commerce Csharp safe to use with an AI agent?

Its trust score is 34 out of 100 (low). It passes 1 of the 1 static security checks run so far. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Commerce Csharp still maintained?

Conduid hasn't recorded a commit date for this repository yet. Check the repository directly for recent activity.