mcp-abap-abap-adt-api
An MCP server for SAP ABAP: an agent finds objects, reads and edits sources, checks syntax and handles transports through ADT
- 211 ★ on the repository
- Last commit
- MIT
Broad access
Why this level
- The `setObjectSource`, `activate` and transport tools change code and objects in SAP within the user's authorizations
- The SAP password or token sits in the client configuration, and the Git tools ask SAP to contact a remote repository with supplied credentials
Install
- Works in
Manual install
npm ci && npm run buildRun in the cloned repository; Node.js 22.22.2 or newer is required.
Access and checks
How we reviewBroad accessThe tool can change data, run commands or handle secrets.
- The `setObjectSource`, `activate` and transport tools change code and objects in SAP within the user's authorizations
- The SAP password or token sits in the client configuration, and the Git tools ask SAP to contact a remote repository with supplied credentials
This is third-party code. Review the repository files before installing.
What it does
mcp-abap-abap-adt-api wraps the abap-adt-api library and gives an agent 127 ABAP Development Tools tools plus `readResultPage` for large results. An agent finds objects (`searchObject`), reads sources (`getObjectSource`), locks an object, writes a new version (`setObjectSource`), checks syntax (`syntaxCheckCode`), activates and handles transport requests. It also covers data queries, debugging, refactoring, Git operations and code analysis. All calls share one SAP session owned by a local stdio client. The SAP user's authorizations decide what is allowed: the server adds no read or write limits of its own. Results over 64 KiB come back in pages: the server returns a `resultId`, the next offset and an expiry, and `readResultPage` reassembles the original result. Input schemas are derived from abap-adt-api 8.4.3 declarations and unknown arguments are rejected. A snapshot of the last source read can go straight to a syntax check without resending the code.
Who it is for. ABAP developers and SAP administrators who work in the system through an agent: editing class and program sources, checking syntax, attaching changes to transports.
Good fit when
- An ABAP class or program has to be fixed from a description: the agent finds the object with `searchObject`, reads the source, locks it and writes a new version
- You want to check syntax before activation: `syntaxCheckCode` takes the last source read or written when `code` is omitted
- A change must land in a transport request: `transportInfo` returns the request number for an object
- An SAP export is large and the client truncates the response: `readResultPage` reassembles JSON from pages
- Access is checked read-only before working on a real system: `npm run verify:live` with `SAP_LIVE_TEST=1` runs a login and discovery check
Not a fit when
- You need an HTTP server or OAuth sign-in for several users: the package runs over stdio and targets one trusted operator
- You need OS-level isolation: the server process is unrestricted and access is set only by the SAP user's authorizations
- The SAP certificate comes from a private authority and `NODE_EXTRA_CA_CERTS` cannot be set: TLS verification cannot be switched off
- Several agents must work with SAP in parallel: there is one session and overlapping calls get a busy error
Example request
Find the SAP class ZCL_INVOICE_XML_GEN_MODEL, read its source and show where the XML header is built, without writing anythingMCP
- Transport
- stdio
- Authentication
- API key
Environment variables
SAP_URLrequired- SAP system address as an origin without a path, query or credentials
SAP_USERrequired- SAP user
SAP_PASSWORDrequired, secret- SAP user password; SAP_BEARER_TOKEN can replace it
SAP_BEARER_TOKENsecret- Static token of an authorized broker instead of a password
SAP_CLIENT- SAP client number
SAP_LANGUAGE- SAP sign-in language
SAP_REQUEST_TIMEOUT_MS- Request timeout, 100 to 120000 ms, default 60000
Limitations
- No npm release is published: the server is built from source with `npm ci` and `npm run build`, and needs Node.js 22.22.2 or newer (or 24.15.0 and newer).
- Requests to SAP have a timeout: 60 seconds by default, and `SAP_REQUEST_TIMEOUT_MS` accepts 100 to 120000. The server does not follow redirects or use environment proxies.
- The README's live check is read-only: the author advises trying writes, debugging, Git and transports on a development system.
- `SAP_URL` is given as an origin without a path or query.
How to disable. Remove the `abap-adt` entry from the MCP client configuration and restart the client. The SAP session is ended with the `logout` or `dropSession` tools, and the local build is deleted with the repository folder.
FAQ
How do I connect mcp-abap-abap-adt-api to Claude Code or Cursor?
Build the project (`npm ci`, then `npm run build`) and add a server to the client configuration with the command `node` and the absolute path to `dist/index.js`. Put `SAP_URL`, `SAP_USER`, `SAP_PASSWORD`, `SAP_CLIENT` and `SAP_LANGUAGE` in the `env` block.
Which environment variables are needed to sign in to SAP?
`SAP_URL` and credentials are required: `SAP_USER` with `SAP_PASSWORD`, or a static token from an authorized broker in `SAP_BEARER_TOKEN`. A `.env` file is loaded only when its path is set in `SAP_ENV_FILE`.
Why does healthcheck pass while SAP is unreachable?
`healthcheck` reports local configuration and session recovery state but does not verify the connection to SAP. To check sign-in use `npm run verify:live` with `SAP_LIVE_TEST=1`.
In what order does the agent change ABAP source?
It finds the object with `searchObject`, reads the source with the `/source/main` suffix, gets the transport via `transportInfo`, locks the object with `lock`, writes code with `setObjectSource` and checks `syntaxCheckCode`. `activate` and `unLock` remain.
Does the server work with an HTTP SAP address?
HTTPS with certificate verification is expected by default. HTTP on loopback is allowed for test fixtures, and a private network needs `SAP_ALLOW_HTTP=1`, which sends credentials over the network in clear text.
Discussion
No questions or reviews yet.
Related
MCP serversThe MCP server turns OpenAPI operations into agent tools and sends real requests to the configured REST API.
An MCP server that lets an agent read files, search code and run commands in a workspace
Ref's MCP server: documentation search for APIs and libraries that hands the agent only the relevant parts of pages
An MCP server that indexes code with tree-sitter and returns individual functions and classes to the agent instead of whole files
A 1C external data processor with MCP and REST API: queries, metadata, event log and code execution without changing the configuration
Firmware references for an agent: registers, Modbus and SCPI with a quote and page number, and a refusal instead of a guess when data is missing
README in short
The top of the page covers the build, MCP client configuration and environment variables, then session rules, limits and safety boundaries. Next come acceptance checks (build, tests, stdio, package, Docker) and a list of related pull requests. The lower half is left from earlier versions: a model instruction listing key tools and a step-by-step code editing workflow.