PP/DS MCP Server

PP/DS MCP Server

Enables AI-assisted planning inquiries by exposing PP/DS OData APIs as MCP tools for SAP S/4HANA, allowing natural language queries about planned orders, production orders, and work centers.

Category
Visit Server

README

PP/DS MCP Server – Projektdokumentation

Ziel

KI-gestützte Planungsauskunft direkt in SAP: Eine Custom Fiori App im S/4HANA PCE System schickt Planungsfragen an SAP AI Core, der über den MCP-Server auf PP/DS-Daten zugreift und die Antwort direkt zurück in die Fiori App liefert.


Architektur (Zielzustand)

┌─────────────────────────────────┐
│       S/4HANA Private Cloud     │
│                                 │
│  ┌──────────────────────────┐   │
│  │  Custom Fiori App        │   │
│  │  (Input: Frage + Kontext)│   │
│  └────────────┬─────────────┘   │
│               │ OData/HTTP      │
│  ┌────────────▼─────────────┐   │
│  │  BTP Integration / ABAP  │   │
│  │  HTTP Outbound Call      │   │
│  └────────────┬─────────────┘   │
└───────────────┼─────────────────┘
                │ Cloud Connector / Private Link
                ▼
┌─────────────────────────────────┐
│          SAP BTP                │
│                                 │
│  ┌──────────────────────────┐   │
│  │  SAP AI Core             │   │
│  │  Orchestration Service   │   │
│  └────────────┬─────────────┘   │
│               │ MCP Tool Calls  │
│  ┌────────────▼─────────────┐   │
│  │  PP/DS MCP Server        │   │
│  │  (dieses Repo)           │   │
│  │  odata-mcp-proxy         │   │
│  └────────────┬─────────────┘   │
│               │ OData           │
└───────────────┼─────────────────┘
                │ Cloud Connector / Private Link
                ▼
┌─────────────────────────────────┐
│       S/4HANA Private Cloud     │
│                                 │
│  ┌──────────────────────────┐   │
│  │  PP/DS OData APIs        │   │
│  │  (Planned/Prod. Orders,  │   │
│  │   Work Centers, ...)     │   │
│  └──────────────────────────┘   │
└─────────────────────────────────┘
                │
                │ Antwort zurück durch denselben Pfad
                ▼
        Custom Fiori App Output

Datenpfad:

  1. Fiori App sendet Frage + Kontextdaten (z.B. Planauftragsnummer, Werk) an AI Core
  2. AI Core Orchestration versteht die Anfrage, wählt passende MCP-Tools
  3. MCP-Server ruft die PP/DS OData APIs im S/4HANA PCE ab
  4. Antwort läuft zurück: MCP → AI Core → Fiori App

Komponenten

1. Custom Fiori App (S/4HANA PCE)

  • Eingebettet in SAP-Transaktion oder eigenständige App
  • Sendet strukturierten Kontext an AI Core (z.B. aktuell geöffneter Planauftrag, Werk, Zeitraum)
  • Zeigt die AI-Antwort direkt in der UI an
  • Tech: SAP UI5 / Fiori Elements, ABAP OData oder CAP Backend

2. SAP AI Core (BTP)

  • Orchestration Service als zentrales AI-Brain
  • Nimmt die Anfrage der Fiori App entgegen
  • Entscheidet welche MCP-Tools aufgerufen werden
  • Gibt formatierte Antwort zurück

3. PP/DS MCP Server (dieses Repo, BTP CF)

  • Powered by odata-mcp-proxy
  • Exposes PP/DS OData APIs als MCP-Tools
  • Kein eigener Code — nur api-config.json
  • Läuft auf BTP Cloud Foundry, nutzt Destination Service + Cloud Connector

4. S/4HANA PCE OData APIs

  • Planaufträge (API_PLANNED_ORDERS)
  • Fertigungsaufträge (API_PRODUCTION_ORDERS_2_SRV)
  • Arbeitsplätze (API_WORK_CENTER_SRV)
  • Erweiterbar via Custom CDS Views

BTP Deployment (MCP Server)

Voraussetzungen

  • SAP BTP Subaccount (Cloud Foundry aktiviert)
  • Cloud Connector konfiguriert mit Virtual Host für S/4HANA PCE
  • BTP Destination S4H_PCE angelegt (OnPremise, Basic oder OAuth2SAML)
  • Services: Destination, Connectivity, XSUAA

BTP Destination S4H_PCE

Property Wert
Name S4H_PCE
Type HTTP
URL Virtual Host (Cloud Connector)
Authentication BasicAuthentication oder OAuth2SAMLBearerAssertion
Proxy Type OnPremise

Deployment

npm install -g mbt
mbt build
cf login -a https://api.cf.<region>.hana.ondemand.com
cf deploy mta_archives/ppds-mcp-server_1.0.0.mtar

API Konfiguration (api-config.json)

Drei API-Gruppen, read-only:

API EntitySets Use Case
API_PLANNED_ORDERS PlannedOrder, PlannedOrderComponent, PlannedOrderCapacity Planaufträge lesen, Komponenten, Kapazitätsbedarfe
API_PRODUCTION_ORDERS_2_SRV ProductionOrder, ProductionOrderOperation Fertigungsaufträge + Vorgänge
API_WORK_CENTER_SRV WorkCenter Arbeitsplätze / Ressourcen

→ Details in api-config.json


Beispiel-Interaktionen

Fiori App schickt an AI Core (mit Kontext Werk=1000, Material=FG-001):

„Welche Planaufträge für Material FG-001 laufen diese Woche?" → AI Core → PlannedOrder_list mit $filter auf Material + Datum → Antwort in Fiori

„Auf welchem Arbeitsplatz wird Planauftrag 1234567 gefertigt?" → AI Core → PlannedOrderCapacity_get → WorkCenter aus Ergebnis → Antwort

„Welche Komponenten fehlen für Planauftrag 1234567?" → AI Core → PlannedOrderComponent_list → Abgleich mit Verfügbarkeit → Antwort


Covered Use Cases (Phase 1 – Read-only)

Frage API / EntitySet
Welche Planaufträge laufen diese Woche für Werk X? PlannedOrder
Details zu Planauftrag XXXXXXX? PlannedOrder GET
Welche Komponenten braucht Planauftrag X? PlannedOrderComponent
Kapazitätsbedarf für Planauftrag X? PlannedOrderCapacity
Status Fertigungsauftrag X? ProductionOrder GET
Welche Vorgänge hat Fertigungsauftrag X? ProductionOrderOperation
Alle offenen Aufträge für Material Y? ProductionOrder ($filter)
Welche Arbeitsplätze gibt es in Werk Z? WorkCenter

Roadmap

  • [x] MCP Server Konfiguration (api-config.json)
  • [x] BTP Deployment Setup (mta.yaml, xs-security.json)
  • [ ] BTP Deployment ausführen + testen
  • [ ] AI Core Orchestration: MCP-Tools registrieren
  • [ ] Custom Fiori App: AI Core Integration (Input/Output)
  • [ ] Phase 2: Write-Operationen (Planauftrag ändern)
  • [ ] Custom CDS Views für Lücken (aggregierte Kapazitätsauslastung, Alerts)

Referenzen

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured