Command Palette

Search for a command to run...

UnylyUnyly
Весь каталог

Production Plan Variance Server

БесплатноНе проверен

Exposes read-only tools for querying production plan variance, issue tracking, plants, and shop floors from a DWH database, mirroring a dashboard's data.

GitHubEmbed

Описание

Exposes read-only tools for querying production plan variance, issue tracking, plants, and shop floors from a DWH database, mirroring a dashboard's data.

README

A small MCP server that exposes the Production Plan Variance & Issue Tracking dashboard (erp.peopledesk.io/production-management/mes/ProductionPlanVariance) as five read-only tools, backed directly by the DWH database:

Tool Mirrors
get_variance_summary The four tiles: Plan Lines / On Target / Variance Flagged / Issues Missing
list_plan_variance The row grid (plan code, item, plant, qty, difference, reason, status)
list_variance_reasons The "Issue for Difference" reason config + escalation emails, per plant
list_plants Plant filter dropdown
list_shop_floors Shop Floor filter dropdown

It queries these DWH tables (verified against the live schema): tblProductionPlanVarianceIssueArc, tblProductionPlanVarianceReasonArc, tblPlantArc, tblShopFloorArc.

Why this shape

You asked for something anyone can use via a JSON file, without anyone entering database credentials. So the design is:

  • One server, hosted by you, holding the DB credentials in its own environment variables (.env, never committed, never sent to clients).
  • Everyone else just drops mcp-config.json into their MCP client (Claude Desktop, Claude Code, etc.) — it only contains a URL, nothing secret. The server is the only thing that talks to SQL Server.
  • All queries are fixed, parameterized SELECTs defined in src/queries.js — there is no free-form SQL tool exposed, so nobody using this MCP server can query outside the dashboard's own data or run writes.

⚠️ Before you deploy: confirm DB permissions

While building this, I verified the schema (tables/columns) using your mssql-test-server connection, but every actual row-level SELECT against tblProductionPlanVarianceIssueArc / tblPlantArc etc. failed — schema introspection worked, data queries didn't. That's almost certainly a permissions gap on that specific SQL login (mcp_user), not a problem with these queries. Before going live:

  1. Create (or reuse) a SQL Server login with SELECT-only rights on the DWH tables listed above.
  2. Test manually, e.g.:
    SELECT TOP 5 * FROM dbo.tblProductionPlanVarianceIssueArc;
    
  3. Only then point DB_USER/DB_PASSWORD in .env at that login.

Deploy

Option A — your own server (nginx/Caddy in front)

npm install
cp .env.example .env    # fill in DB_SERVER / DB_USER / DB_PASSWORD
npm start                # listens on :3300, endpoint POST /mcp

Put it behind HTTPS on a domain reachable by your team, e.g. https://mcp.yourcompany.com/mcp.

Option B — Vercel (already set up in this repo)

The api/mcp.js + vercel.json files convert the same server into a Vercel serverless function, exposed at /mcp.

  1. Push this folder to a GitHub repo (or run from the folder directly).
  2. Install the CLI once: npm i -g vercel
  3. From inside production-variance-mcp/, log into your own Vercel account and deploy:
    vercel login
    vercel --prod
    
  4. In the Vercel dashboard → your project → Settings → Environment Variables, add DB_SERVER, DB_PORT, DB_DATABASE, DB_USER, DB_PASSWORD, DB_ENCRYPT, DB_TRUST_CERT (same values as .env.example), then redeploy so the function picks them up.
  5. Your MCP endpoint is now https://<your-project>.vercel.app/mcp. Put that URL into mcp-config.json and hand it out.

Note: SQL Server must be reachable from Vercel's network (i.e. not firewalled to only your office IP) — check with whoever manages 203.202.241.211 if the connection times out after deploying. Also add some form of auth in front of /mcp (see note below) before this URL is public — right now anyone with the link can call these read-only tools.

Distribute

Edit mcp-config.json, replacing YOUR-HOSTED-DOMAIN with your real domain, then share that one file. Anyone adds it to their MCP client and immediately has read-only chat access to this dashboard's data — no install, no credentials, no SQL knowledge required.

Notes / things to double check on your end

  • The dashboard's "Machine" column (e.g. "Aromatic Unit Line - 01") wasn't found on tblProductionPlanVarianceIssueArc in the schema I pulled — it's likely resolved via a production line/work-center table in your environment. list_plan_variance's query doesn't include it yet; add the appropriate JOIN in src/queries.js once you confirm the source table (candidates: tblProductionLineArc, tblWorkCenterArc).
  • get_variance_summary's "Issues Missing" logic assumes it means "flagged variance with no reason/status recorded yet" — confirm this against the app's actual business logic and adjust QUERY_SUMMARY if different.
  • Add auth (API key / OAuth) in front of /mcp before exposing it beyond your internal network — this build has none by default.

from github.com/sauravakij/AR-PP-MCP

Установка Production Plan Variance Server

У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.

▸ github.com/sauravakij/AR-PP-MCP

FAQ

Production Plan Variance Server MCP бесплатный?

Да, Production Plan Variance Server MCP бесплатный — установка в пару кликов через Unyly без оплаты.

Нужен ли API-ключ для Production Plan Variance Server?

Нет, Production Plan Variance Server работает без API-ключей и переменных окружения.

Production Plan Variance Server — hosted или self-hosted?

Доступен hosted-вариант: Unyly запускает сервер в облаке, локальная установка не обязательна.

Как установить Production Plan Variance Server в Claude Desktop, Claude Code или Cursor?

Открой Production Plan Variance Server на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.

Похожие MCP

wenb1n-dev/SmartDB_MCP

A universal database MCP server supporting simultaneous connections to multiple databases. It provides tools for database operations, health analysis, SQL optim

wenb1n-devавтор: wenb1n-dev

Postgres Server

This server enables interaction with PostgreSQL databases through the Model Context Protocol, optimized for the AWS Bedrock AgentCore Runtime. It provides tools

madhurprashавтор: madhurprash

Postgres

Query your database in natural language

Anthropicавтор: Anthropic

PostgreSQL

Read-only database access with schema inspection.

modelcontextprotocolавтор: modelcontextprotocol

Redis

Interact with Redis key-value stores.

modelcontextprotocolавтор: modelcontextprotocol

SQLite

Database interaction and business intelligence capabilities.

modelcontextprotocolавтор: modelcontextprotocol

mxcp

Open-source framework for building enterprise-grade MCP servers using just YAML, SQL, and Python, with built-in auth, monitoring, ETL and policy enforcement.

raw-labsавтор: raw-labs

tadas-github/a2asearch-mcp

MCP server to search 4,800+ MCP servers, AI agents, CLI tools and agent skills. Install: npx -y a2asearch-mcp. Ask Claude: "Find MCP servers for database access

tadas-githubавтор: tadas-github

julien040/anyquery

Query more than 40 apps with one binary using SQL. It can also connect to your PostgreSQL, MySQL, or SQLite compatible database. Local-first and private by desi

julien040автор: julien040

drakonkat/wizzy-mcp-tmdb

A MCP server for The Movie Database API that enables AI assistants to search and retrieve movie, TV show, and person information.

drakonkatавтор: drakonkat

Compare Production Plan Variance Server with

Не уверен что выбрать?

Найди свой стек за 60 секунд

Автор?

Embed-бейдж для README

Похожее

Все в категории data