Get the FREE Ultimate OpenClaw Setup Guide →

McpServer

A Model Context Protocol (MCP) server for supermarket inventory and sales management. Provides AI assistants with real-time access to product data, sales analytics, inventory tracking, and business intelligence tools through standardized MCP protocol integration.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio darko-martinovic-mcpserver dotnet run --webapi \
  --env ASPNETCORE_URLS="http://localhost:5000" \
  --env ConnectionStrings__DefaultConnection="Server=your-server;Database=your-db;Integrated Security=true;TrustServerCertificate=true;"

How to use

This MCP server provides a dual-mode experience for a modern supermarket ecosystem. In Web API mode, it exposes versioned REST endpoints under /api/v1 for inventory, sales, revenue, and analytics via a plugin-based architecture that includes a SQL Server-backed Supermarket plugin and a MongoDB-backed ThirdApi plugin. The server also includes a unified Tool Proxy that lets you execute MCP tools by name through a single endpoint, and it supports Claude Desktop or MCP Inspector integrations in Console/MCP mode for AI-assisted workflows. In console/MCP mode, you can run the server as a tool provider without the web API surface, enabling Claude Desktop configurations to invoke tools locally. The API versioning strategy (e.g., /api/v1/...) ensures future compatibility as new endpoints and plugins are added. Tools can be executed via /api/v1/tool, probes via /api/v1/proxy/health, and data retrieval via the various /api/v1/supermarket and /api/v1/thirdapi endpoints. The system supports server-side logging, health checks, and plugin health endpoints for maintainability.

How to install

Prerequisites:

  • .NET 9.0+
  • SQL Server 2014+ (for Supermarket plugin)
  • MongoDB 4.0+ (for ThirdApi plugin, optional)

Setup steps:

  1. Database: Create and seed the database
    • Run Database/SetupDatabase.sql to create tables and sample data
  2. Configure: Edit appsettings.json with your SQL Server connection string
  3. Build:
    dotnet build
    
  4. Run (Web API mode):
    dotnet run --webapi
    
  5. Run (Console/MCP mode):
    dotnet run
    
    • This starts the server in console/MCP provider mode suitable for Claude Desktop or MCP Inspector integrations
  6. Optional Claude Desktop integration example (config):
    {
      "mcpServers": {
        "darko-martinovic-mcpserver": {
          "command": "dotnet",
          "args": ["run", "--project", "/path/to/your/McpServer", "--no-build"]
        }
      }
    }
    
    • Place this config where Claude Desktop expects it (see CLAUDE config guidance in README)

Notes:

  • Ensure your appsettings.json contains a valid SQL Server connection string for the Supermarket plugin
  • If you enable MongoDB interactions (ThirdApi), ensure MongoDB is running and the default connection string is configured

Additional notes

Tips and considerations:

  • API Versioning: All endpoints are exposed under /api/v1 for forward compatibility; monitor api-supported-versions headers for available versions.
  • Logging: Serilog-based logging writes to file and console; check Logs/mcpserver.log for issues.
  • Environment variables: Override database connections via environment variables (e.g., ConnectionStrings__DefaultConnection) when deploying.
  • Health checks: Use /health and /api/v1/proxy/health (tool proxy) to verify service health and plugin status.
  • Claude Desktop integration: In Console/MCP mode, configure Claude to point to the MCP server and utilize the unified tool proxy endpoints to execute tools by name.
  • Plugins: The architecture supports adding new plugins easily; each plugin provides tools, REST endpoints, and health checks.

Related MCP Servers

Sponsor this space

Reach thousands of developers