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.
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:
- Fiori App sendet Frage + Kontextdaten (z.B. Planauftragsnummer, Werk) an AI Core
- AI Core Orchestration versteht die Anfrage, wählt passende MCP-Tools
- MCP-Server ruft die PP/DS OData APIs im S/4HANA PCE ab
- 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_PCEangelegt (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_listmit $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
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
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.
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.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
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.
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.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
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.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.