Skip to main content
Glama
xiaoliang2

dsh-abap-mcp

by xiaoliang2

dsh-abap-mcp

⚠️ Experimental Stage · EXPERIMENTAL

This plugin is still in the experimental stage (Experimental) and is intended for Dev/Test environments only.

  • Do not connect directly to production systems. Even though it is read-only by default, read-only tools can still read source code and business data from production systems.

  • Use a least-privilege SAP account to connect.

  • The write permission switches (sourceWrite / transports / refactor / exec / git / debug / serviceBinding) are all disabled by default; enable them only on development systems, as needed and with caution.

  • Passwords are stored in plaintext in the local settings.yaml; be mindful of credential security.

By using this plugin, you acknowledge the above risks and assume all consequences yourself.

DeepSeek Harness plugin: connects to SAP ABAP ADT via MCP, allowing you to query/read ABAP objects in SAP directly from DSH. Strictly read-only by default, with 7 categories of write permissions available as configurable switches.

Upstream server: mario-andreschak/mcp-abap-abap-adt-api This plugin bundles a permission-layered copy of the server in server/ (read-only by default + switches), and handles connection, tool registration, and reconnection on settings changes.


Architecture

DSH 设置页卡片(ABAP MCP)
        │  settingsScope.set(...)   ←→  settings/updated
        ▼
Host 插件 lib/index.js
  1. settings.register("abap-mcp", schema)   # 连接配置 + 7 类权限开关 + 状态
  2. spawn `node server/dist/index.js`(StdioClientTransport,env=SAP_* + MCP_ABAP_PERMISSIONS)
  3. MCP Client 连接,把服务器工具注册为 mcp__abap__<tool>
  4. 配置变更 → 去抖重连;连接断开 → 有界退避重试
        ▼
server/dist/index.js(MCP 服务器,权限在这里强制生效)
  - MCP_ABAP_PERMISSIONS 未设置 → 默认只读(约 75 个只读工具)
  - 7 类写权限通过 MCP_ABAP_PERMISSIONS 的 JSON 开关启用
  • The single source of truth for permissions lives on the server side: the Host merely passes the switch values through to the server; both the tool list and invocations are filtered/rejected according to permissions. Even if someone bypasses DSH and connects directly to the server, permissions still take effect.

  • Tool naming: mcp__abap__<tool name> (e.g. mcp__abap__searchObject).

Related MCP server: vibing-steampunk

Permission Model (default = strictly read-only)

The permission model is enforced on the server side (server/src/permissions.tsdist/permissions.js). The read-only core is always enabled by default; the 7 categories of write permissions are all off by default and can be enabled per category via the MCP_ABAP_PERMISSIONS environment variable. Any tool not registered is denied (deny-by-default); newly added handlers will not silently open up access.

Read-Only Core (~75 tools, always enabled)

Subgroup

Tools

Description

Auth / Session

login logout dropSession

Login / logout / clear local session cache

Object Discovery

objectStructure searchObject findObjectPath objectTypes reentranceTicket

Query object structure / search / locate path / object types / reentrance ticket

Class Introspection

classIncludes classComponents

Class include composition / component list

Code Analysis (read-only)

syntaxCheckCode syntaxCheckCdsUrl codeCompletion findDefinition usageReferences syntaxCheckTypes codeCompletionFull codeCompletionElement usageReferenceSnippets fixProposals fixEdits fragmentMappings abapDocumentation

Syntax check / completion / definition navigation / reference query / fix suggestions / documentation (read-only)

Source Reading

getObjectSource

Read object source

Inactive Objects

inactiveObjects

List inactive objects

Registration / Validation

objectRegistrationInfo validateNewObject

Object registration info / new object parameter validation (read-only)

Transport Reading

transportInfo hasTransportConfig transportConfigurations getTransportConfiguration userTransports transportsByConfig systemUsers transportReference

Transport request info / user transports / configuration / system users (read-only)

Repository Browsing

nodeContents mainPrograms

Object tree browsing / include main programs

Features / Discovery

featureDetails collectionFeatureDetails findCollectionByUrl loadTypes adtDiscovery adtCoreDiscovery adtCompatibiliyGraph

ADT capability discovery / feature query

Unit Test Result Reading

unitTestEvaluation unitTestOccurrenceMarkers

Evaluate unit test results / marker positions (read-only)

Formatter Settings Reading

prettyPrinterSetting

Read formatter settings (no modification)

Git Reading

gitRepos gitExternalRepoInfo checkRepo remoteRepoInfo

Repository list / remote info / check (read-only)

DDIC Reading

annotationDefinitions ddicElement ddicRepositoryAccess packageSearchHelp

Annotations / DDIC elements / package search (read-only)

Service Binding Details

bindingDetails

Service binding details (read-only)

Data Reading

tableContents runQuery

Table data / SQL queries (read-only)

Feeds / Dumps

feeds dumps

Dynamic object list / short dump list

Rename Analysis

renameEvaluate renamePreview

Rename evaluation / preview (executed only, not persisted)

ATC Reading

atcCustomizing atcCheckVariant atcWorklists atcUsers isProposalMessage atcContactUri

ATC check configuration / variants / worklists / users / contacts (read-only)

Trace Reading

tracesList tracesListRequests tracesHitList tracesDbAccess tracesStatements

Trace list / requests / hits / DB access / statements (read-only)

Revisions / Health

revisions healthcheck

Object revision history / connection health check

7 Categories of Write Permissions (all off by default)

Switch

Subcategory

Tools

Description

sourceWrite

Source write

setObjectSource deleteObject activateObjects activateByName createObject createTestInclude lock unLock

Write source / delete object / activate / create object / create test include / lock and unlock

transports

Transport requests

createTransport setTransportsConfig createTransportsConfig transportDelete transportRelease transportSetOwner transportAddUser

Create / configure / delete / release / change owner / add user

refactor

Refactoring

renameExecute extractMethodEvaluate extractMethodPreview extractMethodExecute prettyPrinter setPrettyPrinterSetting

Rename execute / extract method (evaluate/preview/execute) / format (read/write)

exec

Execution

runClass unitTestRun

Run ABAP class / run unit tests

ATC write operations

createAtcRun atcExemptProposal atcRequestExemption atcChangeContact

Start ATC check / exemption proposal / request exemption / change contact

Trace configuration

tracesSetParameters tracesCreateConfiguration tracesDeleteConfiguration tracesDelete

Set trace parameters / create config / delete config / delete records

git

Git write operations

gitCreateRepo gitPullRepo gitUnlinkRepo stageRepo pushRepo switchRepoBranch

Create repo / pull / unlink / stage / push / switch branch

debug

Debugging

debuggerListeners debuggerListen debuggerDeleteListener debuggerSetBreakpoints debuggerDeleteBreakpoints debuggerAttach debuggerSaveSettings debuggerStackTrace debuggerVariables debuggerChildVariables debuggerStep debuggerGoToStack debuggerSetVariableValue

Listen / breakpoints / attach / step / stack / variable read-write

serviceBinding

Service binding

publishServiceBinding unPublishServiceBinding

Publish / unpublish OData service binding

Note: In the read-only core, "ATC read", "trace read", "Git read", and "transport read" are read-only; only the write tools in the corresponding categories (start checks, change configs, push code, publish services, etc.) require permissions. Previewing before rename (renameEvaluate/renamePreview) is read-only; only the actual execution (renameExecute) requires refactor.

Manual permission confirmation (prevents AI from enabling permissions on its own)

When enabling any permission switch, the plugin requires manual confirmation: when a settings page card is checked, a one-time confirmation credential (confirm-<timestamp>-<random string>) is generated and written to the config. The Host side only allows connection in the corresponding mode when the credential is fresh (within 60 seconds) and correctly formatted; otherwise it forcibly falls back to read-only and shows "manual confirmation required on settings card" in the status. This mechanism covers all 7 categories of permission switches (sourceWrite / transports / refactor / exec / git / debug / serviceBinding), treating them all equally.

  • Permissions can only be enabled through the settings page card. Enabling via the settings API / directly editing settings.yaml / asking the model to modify permissions in a conversation will all be rejected due to the missing valid credential.

  • The credential has a 60-second validity period and expires automatically after restart; it must be re-issued via the card.

  • Turning off all permissions (back to all-off) requires no confirmation and is always allowed.

Installation

From npm (official package)

dsh plugin add @xiaobanli/dsh-abap-mcp

Local directory (development/integration testing)

Add the dependency to the profile's package.json and run pnpm install:

{
  "dependencies": {
    "@xiaobanli/dsh-abap-mcp": "link:C:/othersoftware/harness/harness/project6/dsh-abap-mcp"
  },
  "dsh": { "profile": { "bundles": [ "...", "dsh-abap-mcp" ] } }
}

After restarting DSH, the "ABAP MCP" card will appear on the left side of the settings page.

Configuration (settings page card)

Prerequisites (please confirm before connecting)

  1. The ADT service node must be enabled in transaction SICF on the SAP side: the plugin accesses SAP via the HTTP(S) service of ABAP Development Tools (ADT). If the relevant ADT service nodes are not activated, the connection will fail. Generally, activating default_host/sap/bc/adt and its sub-nodes in SICF is sufficient (the exact nodes vary slightly by system version).

  2. SAP address format: most are http://address:port or https://address:port (some higher versions/gateway configurations use the full path http://address:port/sap/bc/adt). Please confirm the protocol and port according to your actual system, e.g., http://10.0.0.1:8000 or https://sap.example.com:44300.

Field

Description

Enable connection

Master switch; when off, no connection is made and no tools are registered

SAP address

e.g., http://address:port / https://address:port (ADT service must be enabled first)

Username / Password

Connection credentials

Client / Language

e.g., 000 / EN

7 write permission switches

Check to enable the corresponding write capability

After saving, the Host automatically reconnects; you can also ask the model abap_mcp_status directly in the conversation to check the connection status.

"Test Connection" button: first persists the current form to disk, then uses the current configuration to perform a real spawn → connect → tool enumeration → disconnect cycle. The result (success/failure, elapsed time, tool count) is displayed next to the button; it does not change the "Enable connection" switch state.

  • If SAP address / username / password are not filled in, the button directly prompts "Please fill in the configuration first" without running an empty test.

  • While the test is running, the button shows "Testing…"; if there is no result within 60 seconds, it automatically times out and prompts.

  • The test result (status.lastTest) remains displayed next to the button and is not cleared by reconnect status refreshes.

  • The test is a one-time action: it does not trigger a persistent connection or auto-reconnect, and a failed test does not enter backoff retry; only configuration changes (enable switch/connection fields/permissions) trigger a persistent connection with bounded retries (giving up after at most 5 attempts).

Building the server (after modifying server/)

cd server
npm install --ignore-scripts   # 依赖均为纯 JS,无需生命周期脚本
node node_modules/typescript/bin/tsc -p tsconfig.json   # 产出 dist/

Troubleshooting

"Test Connection" keeps showing "Testing…", or clicking it does nothing

  • Most likely the settings write did not persist to disk. Confirm that the SAP address / username / password are all filled in; the plugin writes settings back to the local settings.yaml.

  • If it keeps getting stuck, check the DSH logs for SettingsConflictError (settings revision conflict causing the write to be discarded) — restart DSH and try again.

Connection reports McpError: Connection closed

  • The desktop host runs in Electron, so the child process needs to start in Node mode (the plugin already sets ELECTRON_RUN_AS_NODE=1 automatically).

  • If it still occurs, confirm that server/dist/index.js exists (no rebuild needed if the server/ source was not modified); if node server/dist/index.js stays alive in the terminal, the server itself is fine.

A write permission switch is enabled, but the corresponding tool does not appear

  • Permissions actually take effect on the server side: after saving the switch, the plugin reconnects and re-enumerates the tools (the tool count should increase, e.g., 75 → 83).

  • If the tool count for read-only permissions does not change, check whether abap_mcp_status's mode has changed to read-only + <category>; if it is still read-only, the switch was not saved successfully.

Tool behavior does not change after modifying the server/ source

  • A rebuild is required: cd server && npm install --ignore-scripts && node node_modules/typescript/bin/tsc -p tsconfig.json, then restart DSH so the plugin uses the new dist/.

ABAP reports STRING_OFFSET_TOO_LARGE or similar errors at runtime

  • These errors come from the ABAP program itself being read/executed on the SAP side and are unrelated to the plugin. Use mcp__abap__dumps to view the short dump details, or fix the corresponding program in SE38.

Security notes

  • Read-only ≠ harmless: read-only tools can still read source code and business data from production systems. It is strongly recommended to connect to development/test systems and use a least-privilege account (the permission switches are only guardrails on the DSH side and do not replace SAP-side authorization).

  • The server prints the permission mode and a "recommended for development/test systems only" notice at startup (this is a recommendation + notice, not enforced).

  • Passwords are written in plaintext to the local settings.yaml (persisted by DSH's settings service). For a higher security level, extend it to use the credentials service for storage.

  • The server child process only inherits the SDK whitelist environment variables plus the SAP_* and MCP_ABAP_PERMISSIONS explicitly injected by this plugin; it does not leak the host's other environment variables.

License

MIT. The server portion is copyrighted by the original author mario-andreschak (MIT); this plugin adds a permission layer on top of it.

F
license - not found
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables interaction with SAP ABAP systems through ABAP Development Tools (ADT), providing access to repository objects, source code, where-used analysis, and SQL queries with support for both on-premise and BTP systems.
    2
  • A
    license
    A
    quality
    C
    maintenance
    Enables AI assistants like Claude Code to directly connect to SAP ABAP systems via the ADT REST API with read/write capabilities, featuring AI-friendly high-level tools and built-in safety measures such as read-only mode, prefix whitelisting, and automatic locking.
    9
    MIT
  • F
    license
    A
    quality
    C
    maintenance
    Enables AI agents to read, write, activate, and transport ABAP code in SAP systems via ABAP ADT REST API, without needing SAP GUI.
    4
    24

View all related MCP servers

Related MCP Connectors

  • Connect AI assistants to your GitHub-hosted Obsidian vault to seamlessly access, search, and analy…

  • Code intelligence for coding agents: semantic, AST, graph, and full-text search. 279+ languages.

  • Odoo ERP for AI agents: hosted OAuth endpoint, gated writes, one endpoint for every instance.

View all MCP Connectors

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/xiaoliang2/dsh-abap-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server