Skip to content

SAP GUI Automation

stud0709 edited this page Sep 4, 2026 · 4 revisions

SAP GUI Automation

The sap-dev AI skill includes a dedicated presentation-layer automation engine. It communicates directly with running SAP GUI for Java sessions on your workstation to enable autonomous navigation and screen inspection.


Key Capabilities

  • Zero-Setup Session Detection: Hot-attaches to existing, logged-in SAP GUI for Java sessions without requiring custom connection profiles or command-line parameters.
  • Generic Tree Control API: Complete automation of EnjoySAP and Shell tree controls (double_click, select, expand, collapse, click_link, press_button, change_checkbox, context_menu) with multi-column node inspection.
  • Declarative Table & Cluster Maintenance: Automates single-table (SM30) and view cluster (SM34) maintenance declaratively supporting INSERT, UPDATE, TRANSLATE (multi-language tables), and DELETE with adaptive 1-step/2-step view handling and positioning dialogs (SAPLSPO4:0300).
  • On-Demand Visual & Component Inspection: Extracts complete component hierarchies and captures lossless AWT frame screenshots on demand.
  • Declarative Smart Sequences: Executes multi-step macro sequences with parameter hydration (FIELDS, POSITION_FIELDS, ROWS), dynamic queries, assertions, and checkpoints.

Available MCP Tools

Tool Name Description
sap_gui_inspect Inspects and extracts the visual element hierarchy (fields, buttons, labels, tables, modal dialogs) of a specific SAP GUI window with optional screenshot capture.
sap_gui_action Executes atomic actions on a specific SAP GUI window: sets input fields, clicks buttons, selects tabs, and sends virtual keys (VKeys).
sap_gui_eval Evaluates raw JavaScript directly inside the active SAP GUI session. Bypasses GUI error dialogs and returns exact JSON errors.
sap_gui_read_table Reads and extracts structured table rows and column headers from an active SAP GUI Table Control or ALV Grid with automated pagination.
sap_gui_maintain_table Automates SAP table and view maintenance (SM30) via the attached SAP GUI for Java session. Handles batch changesets, row positioning, row selection, insert, update, delete, multi-language translations, and CTS transport confirmations declaratively.
sap_gui_maintain_cluster Automates SAP View Cluster maintenance (SM34) via the attached SAP GUI for Java session. Handles cluster node navigation, parent-child row selection, insert, update, delete, and CTS transport confirmations declaratively.
sap_gui_execute_sequence Executes a multi-step macro sequence in SAP GUI with parameter substitution, dynamic table-row queries, assertions, and milestone checkpoints.
sap_gui_manage_sequence Manages named, parameterized SAP GUI automation macro sequences in SQLite (save, read, list, delete).
sap_request_gui_permissions Bulk-requests permissions across SAP GUI Guard scopes (TRANSACTION, TABLE_MAINT, CUSTOMIZING) by injecting them into the user's SAP GUI Guard queue for approval.

Setup & Prerequisites

For detailed setup instructions, Java runtime requirements (JDK/JRE 17+), and SAP GUI for Java preferences configuration, see the Setup Guide.

For automating SAP GUI for Java running inside remote desktops, Citrix, or Windows Virtual Desktop (AVD), see the dedicated guide:
👉 Running SAP GUI for Java in VDI

Clone this wiki locally