With the major update of the ABAP development tools MCP server, MCP for ABAP is no longer an experiment. It now works with Claude Code, Copilot, Codex and the other CLI tools, and many of us already use some kind of agent in daily ABAP work.
I have been building and using agents on top of the ADT REST API for a few months, in my own S/4HANA 2023 lab. Instead of another how-to, I would like to open a discussion: where does it really help, where does it fail, and what could we share as a community? My notes first.
1. The first explanation is often plausible and wrong
This is true for people and for agents. A classic: SQL 305 on a CDS view, "single-row query returns more than one row". The usual explanation is a to-one association that finds duplicates. In my lab that alone gave no error: a LEFT OUTER MANY TO ONE JOIN from MARA to MAKT, for a material with 3 texts, returned 3 rows. The 305 only came with a scalar subquery that returned more than one row.
What I learned: wherever an explanation comes from, mine or the agent's, it gets reproduced in a sandbox before I believe it. The test is cheap, the wrong explanation is expensive.
2. Reading standard code is where it shines, if you know the limits
Following a call chain through the Gateway runtime classes, to see which DPC methods are really called, is a job of minutes for an agent and of an afternoon for me.
But tools can lie by silence. In my lab, the where-used list of /IWBEP/IF_MGW_CORE_SRV_RUNTIME showed one custom class and none of the SAP classes that I then saw using it in their source. And a text search across packages only covers what it really opened.
What I learned: an empty result is not proof that something doesn't exist. The agent must say what it did not search.
3. The system is the judge, but test the judge first
For code written by a model, I let the system decide: syntax check, ATC, ABAP Unit. Before trusting the judge, I give it two controls: the correct solution must pass, and a known mistake must fail (for example, the language condition in the WHERE instead of the ON of a text join). If the known mistake passes, "it compiles" is quietly becoming "it is right".
4. Context is the real cost
/IWBEP/CL_MGW_ABS_DATA alone has more than 8,000 lines of source. One whole read of a class like this fills a big part of the context, and everything after it gets slower and more expensive. In my own numbers, most of the cost was the model reading a big context again and again, not the answers it wrote. Reading one method, or searching first and reading after, is the habit that pays.
5. Human in the loop, by habit
Read only by default. Writes only in $TMP in my lab, and only after I say yes. Transports stay with a person. It is the same idea as the "safety by default" policy of the SAP server, and I think it is the right default for everybody.
What I would like to hear from you
- Which tasks really save you time today: investigation and reading, writing new objects, reviews, tests?
- Do you use the official ADT MCP server, a community server, or your own? What made you choose?
- How do you check what the agent tells you before you act on it?
- How do you deal with authorizations and transports when an agent can write?
- What would be worth sharing as a community: AGENTS.md patterns, prompts that work, or a set of "known hard" ABAP questions to test agents on?
If there is interest, I am happy to collect the answers in a follow-up.