open source · ABAP & AI
An ABAP MCP server for SAP ECC 6.0, where the modern tooling cannot reach
abap-mcp-702 is a native ABAP implementation of the Model Context Protocol that runs inside SAP ECC 6.0 / NetWeaver 7.02. It gives an AI agent read-only, authenticated access to the real ABAP repository — source, DDIC and where-used — over JSON-RPC 2.0 through an ICF node. No ADT, no BTP, no adapter process.
The problem: AI stops at the ECC boundary
SAP's own MCP server and the ADT-based AI tooling target the modern ABAP Platform and ABAP Cloud. If your system is ECC 6.0 on NetWeaver 7.02 — which a very large part of the installed base still is — none of that is available to you. So the workflow degrades to copy-pasting source into a chat window, and the model answers about a snippet instead of the system.
The context an agent actually needs for legacy ABAP work is boring and specific: what does this include really contain today, which fields exist on this Z table, and what breaks if I change this function module. All three are read operations the system can answer itself.
Why build it in ABAP
Legacy is where the custom code lives
A very large share of running SAP estates is still ECC 6.0. That is also where two decades of Z code, cloned standard programs and undocumented FORM routines sit. AI assistance is most valuable exactly there — and it is exactly where the modern tooling does not reach.
No ADT, no BTP, no bridge process
The server is ABAP. It is installed with abapGit into a custom package and published through an ICF node. There is no Python adapter to host, no BTP subscription to license and no ADT installation on 7.02 to fight with.
MCP natively, not through a wrapper
It speaks Model Context Protocol directly — JSON-RPC 2.0 over HTTP — so any MCP client connects to it the same way it connects to a filesystem or database server. Point Claude Code at the ICF URL and the SAP system becomes context.
Read-only by construction
There is no write path in the code. Calls execute as the logged-on SAP user, so standard authorisations still gate everything, and object access is limited to custom namespaces. The blast radius of a hallucinating agent is a wrong answer, not a wrong transport.
The four tools
sap_get_source
Returns the real, current source of a custom program, include or class — not a paraphrase and not a stale copy someone pasted into a chat six months ago.
sap_get_ddic
Field list of a table or structure with names, data types, lengths and key flags, so generated code uses the fields that actually exist.
sap_search_objects
Repository search by name pattern — the agent finds the right Z object itself instead of asking you for the technical name.
sap_where_used
Where-used across tables, function modules, classes, methods and FORM routines — the impact analysis step every legacy change needs before it starts.
How a request flows
- 01MCP client (Claude Code, or any MCP-capable agent) issues a JSON-RPC 2.0 request.
- 02The request hits an ICF service node published in the ABAP system over HTTP/HTTPS.
- 03The ABAP handler parses the payload with ajson and dispatches to the requested tool.
- 04The tool reads the repository — source, DDIC, search index or where-used — under the calling user's authorisations.
- 05The result is serialised back as an MCP tool response; the agent now reasons on real system facts.
Security posture
- Read-only: no write, activate or transport path exists in the implementation.
- Calls execute as the authenticated SAP user — existing roles and authorisations apply.
- Object access is restricted to custom namespaces.
- The endpoint is an ordinary ICF node, so it inherits your standard HTTPS and logon setup.
- Install and evaluate in a development system before considering anything beyond it.
Getting started
- 1. Install abapGit and the ajson library in your ABAP system.
- 2. Clone the online repository into a custom package with abapGit and activate.
- 3. Publish the ICF service node and note its URL.
- 4. Register that URL as an MCP server in your client and start asking about real objects.
Tested on ECC 6.0 EHP5 / NetWeaver 7.02. Licensed MIT — full setup detail lives in the repository README.
Frequently asked questions
What is an ABAP MCP server?
An ABAP MCP server is a Model Context Protocol endpoint implemented directly in ABAP inside the SAP system. It exposes repository information — source code, DDIC metadata, object search and where-used lists — as MCP tools, so an AI client such as Claude Code can read the real system instead of guessing from pasted snippets.
Does SAP MCP work on ECC 6.0 or NetWeaver 7.02?
SAP's own MCP server and the ADT-based tooling target modern ABAP Platform and ABAP Cloud releases, so they are not available on ECC 6.0 / NetWeaver 7.02. abap-mcp-702 fills that gap: it is written in plain ABAP for 7.02 syntax and runs in the ECC system itself, with no BTP subscription, no Python bridge and no ADT requirement.
Is it safe to connect an AI agent to a production SAP system?
abap-mcp-702 is read-only by construction — there is no write, no code activation and no transport handling in the implementation. Calls run under the calling SAP user, so existing authorisations apply, and object access is restricted to custom namespaces. It is still recommended to install it in a development system first.
What do I need to install it?
An ABAP system on NetWeaver 7.02 or higher, abapGit to pull the repository, the ajson library for JSON handling, and an ICF service node to publish the HTTP endpoint. Installation is a standard abapGit online repository clone into a custom package.
Which MCP tools does it expose?
Four read-only tools: sap_get_source for the real source of a program, include or class; sap_get_ddic for the field list of a table or structure; sap_search_objects for repository search by name pattern; and sap_where_used for usage across tables, function modules, classes, methods and FORM routines.
Bringing AI into your ABAP practice?
I build and maintain tooling that connects legacy SAP estates to modern AI workflows, alongside 13+ years of ABAP, ABAP on HANA and S/4HANA delivery for global enterprises.
Get in touch