mcp-rap-migrator
Provides tools for migrating SAP Module Pool programs to RAP applications, leveraging SAP ADT REST APIs for analysis, code generation, and activation of ABAP objects.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-rap-migratorMigrate the module pool program SAPMZ_DEMO to RAP. Use package ZMIGRATED and prefix ZR_."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-rap-migrator
AI Agent that migrates SAP Module Pool programs → RAP applications, interactively.
Built on MCP (Model Context Protocol) + Anthropic Claude + SAP ADT REST APIs.
Architecture
Human Developer
↕ approves every step
Orchestrator Agent (Claude claude-sonnet-4-6)
↕ system prompt = MIGRATION_GUIDE.md (loaded once, token-efficient)
mcp-rap-migrator (THIS server) — write/transform tools
↕ delegates read-only calls to
mcp-abap-adt (mario-andreschak) — GetProgram, GetInclude, SearchObject
↕ both call
SAP ADT REST API /sap/bc/adt/
↕
SAP ABAP System (S/4HANA or BTP ABAP)Related MCP server: SAP ADT MCP Server
Why TWO MCP servers?
Server | Responsibility | Reason |
| Read: GetProgram, GetClass, SearchObject | Already built, battle-tested, reuse it |
| Write + Transform: analyze, generate, write, activate | New — wraps ADT write APIs + AI code generation |
Tools (this server)
Tool | Purpose | Step |
| Read + parse Module Pool → structured JSON | 1 |
| JSON analysis → CDS/BDef/Impl ABAP code strings | 2 |
| MANDATORY gate — shows human: what got, analysis, next action | Every step |
| Create Workbench Transport Request in SAP | 3 |
| PUT one ABAP object source via ADT REST | 4 |
| Activate objects, return syntax errors | 5 |
Token Efficiency Design
MIGRATION_GUIDE.mdloaded once as system prompt — not re-sent every callanalyze_module_poolreturns compact JSON (not raw ABAP source)human_checkpointshows only first 30 lines of code previewsErrors: only the error message, not the full XML response body
CSRF token reused across calls — not re-fetched every request
Prerequisites
SAP system with
/sap/bc/adtactive in SICFAlso install:
mcp-abap-adt—npx -y @smithery/cli install @mario-andreschak/mcp-abap-adt --client clineNode.js 20+ and npm
Setup
git clone <this-repo>
cd mcp-rap-migrator
npm install
npm run build
cp .env.example .env
# Edit .env with your SAP credentialsConfigure in Cline / Claude Desktop
{
"mcpServers": {
"mcp-abap-adt": {
"command": "node",
"args": ["C:/PATH/mcp-abap-adt/dist/index.js"],
"env": {
"SAP_URL": "https://your-sap.com:8000",
"SAP_USERNAME": "user",
"SAP_PASSWORD": "pass",
"SAP_CLIENT": "100"
}
},
"mcp-rap-migrator": {
"command": "node",
"args": ["C:/PATH/mcp-rap-migrator/dist/index.js"],
"env": {
"SAP_URL": "https://your-sap.com:8000",
"SAP_USERNAME": "user",
"SAP_PASSWORD": "pass",
"SAP_CLIENT": "100"
}
}
}
}Usage
In Cline or Claude Code, with MIGRATION_GUIDE.md loaded as system prompt:
Migrate the module pool program SAPMZ_DEMO to RAP.
Use package ZMIGRATED and prefix ZR_.The agent will:
Analyze the program → show you what it found → ask permission
Generate all RAP objects → show code preview → ask permission
Create a transport → write each object one-by-one → checkpoint each
Activate all → show results → checkpoint
You control every step.
Extending
Add new tools in src/tools/ and register them in src/index.ts.
Ideas:
generate_odata_service— expose the RAP BO as an OData V4 servicerun_atc_check— run ABAP Test Cockpit on generated objectscompare_behavior— run both old + new, compare DB results
mcp-rap-migrator
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/sharmarhl1994-bit/mcp-rap-migrator'
If you have feedback or need assistance with the MCP directory API, please join our Discord server