{"at":"2026-11-23T00:01:39.404Z","dir":"sent","era":"server_discover","message":{"id":1,"jsonrpc":"2.0","method":"server/discover","params":{"_meta":{"io.modelcontextprotocol/clientCapabilities":{},"io.modelcontextprotocol/clientInfo":{"name":"didrun-lab","version":"0.1.0"},"io.modelcontextprotocol/protocolVersion":"2026-07-28"}}}}
{"at":"2026-11-23T00:01:40.949Z","dir":"received","era":"server_discover","message":{"id":1,"jsonrpc":"2.0","result":{"_meta":{"io.modelcontextprotocol/serverInfo":{"name":"mcp-sap-gui","version":"0.6.0"}},"cacheScope":"private","capabilities":{"extensions":{"io.modelcontextprotocol/ui":{}},"logging":{},"prompts":{"listChanged":false},"resources":{"listChanged":false,"subscribe":false},"tools":{"listChanged":false}},"instructions":"SAP GUI automation server. Controls SAP GUI for Windows via COM scripting.\n\n## Rules (read first)\n\n- **Never guess element IDs.** Discover them on every new screen (`sap_get_screen_elements`, `sap_get_toolbar_buttons`): IDs differ between systems and customizations.\n- **Check `screen.active_window` after every action.** `wnd[1]` or higher is a popup: read it with `sap_get_popup_window` before you go on.\n- **Confirmations.** F11 / Save always asks the user first; `sap_set_confirmation_points` can add `transactions`, `batch_fields`, `field_writes`, `all_writes` and `attach`. A \"declined\" error means the user said no: do not retry the call or reach its result another way. Tell the user and wait for their next instruction. Offer `sap_preview` before significant writes (batch fills, Save) so the user sees the screen and the pending values.\n\n## Getting Started\n\n1. SAP already logged on: `sap_connect_existing`; pass `system` (e.g. 'DEV') when the user named the system. SAP Business Client sessions work too (experimental).\n2. SAP not open: `sap_connect` with the SAP Logon entry.\n3. `sap_get_session_info` shows the current transaction and screen.\n\n## Screen Discovery\n\n`sap_get_screen_elements` with `type_filter` (e.g. \"GuiTextField,GuiCTextField\") and `changeable_only=true` keeps the output small; `sap_read_field` reads one field. A tree docked beside the screen (SM34 view clusters, IMG activities) is not under `wnd[0]/usr`: discovery lists it under `docking_containers` (e.g. `wnd[0]/shellcont`).\n\n## Popup Handling\n\nPopups often follow button presses, Enter, F8 and double-clicks. `sap_get_popup_window` gives the text, the buttons, a classification and a safe next step; `sap_handle_popup` acts on it.\n\n## Tables\n\n`sap_read_table` detects the type (`table_type`). Start with `columns_only=true`, then fetch only `columns=\"COL_A,COL_B\"`.\n- ALV grid (reports): page with `start_row` until `total_rows`; its toolbar is `sap_get_alv_toolbar`.\n- Table control (SM30, SPRO): one read returns the visible rows; page with `start_row=next_start_row` while `has_more` is true. `total_rows` counts empty lines; `empty_rows_from` is where the data ends. To jump to an entry use the \"Position...\" toolbar button, not manual scrolling.\n\n## SPRO and Trees\n\nNever `sap_read_tree` SPRO (1000+ nodes). `sap_search_tree_nodes` searches expanded nodes only: expand parents with `sap_get_tree_node_children(expand=true)`. Run an activity with `sap_click_tree_link(tree_id, node_key, \"2\")`; a double-click opens its documentation. In a view cluster (SM34) use `double_click_tree_item` with the column name (usually \"Column1\").\n\n## Keys and Common Mistakes\n\nEnter confirms, F3 goes back, F8 executes, F11 saves, F12 cancels. F4 is value help on the focused field (`sap_set_focus` first): the popup's classification says what opened (`list`, `date_picker`, `time_picker`, `input_required`), and `sap_get_workflow_guide(\"search_help\", field_id)` covers each. Dropdowns (`cmb`) have no F4: `sap_set_field` takes the entry's key or text. In table maintenance F5 means \"New Entries\", not refresh: check the toolbar tooltips first.\n","resultType":"complete","supportedVersions":["2026-07-28"],"ttlMs":0}}}
{"at":"2026-11-23T00:01:40.950Z","dir":"sent","era":"server_discover","message":{"id":2,"jsonrpc":"2.0","method":"tools/list","params":{"_meta":{"io.modelcontextprotocol/clientCapabilities":{},"io.modelcontextprotocol/protocolVersion":"2026-07-28"}}}}
{"at":"2026-11-23T00:01:41.140Z","dir":"received","era":"server_discover","message":{"id":2,"jsonrpc":"2.0","result":{"_meta":{"io.modelcontextprotocol/serverInfo":{"name":"mcp-sap-gui","version":"0.6.0"}},"cacheScope":"private","resultType":"complete","tools":[{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Connect to an SAP system by its name in SAP Logon Pad.\n\nCredentials are resolved from a .env file (SAP_USER, SAP_PASSWORD,\nSAP_CLIENT, SAP_LANGUAGE) so passwords never appear in MCP tool calls.\nParameters provided here override the .env values (except password).\nIf SAP is already open and logged in, use sap_connect_existing instead.","inputSchema":{"additionalProperties":false,"properties":{"client":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null},"system_description":{"type":"string"},"user":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"required":["system_description"],"type":"object"},"name":"sap_connect","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Connect"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Connect to an already open SAP session. Use this when SAP is already logged in.\n\nThis is the most common starting point. connection_index=0 and session_index=0\nconnect to the first open session. Also attaches to SAP Business Client /\nembedded SAP GUI sessions. Indexes come from sap_list_connections; a\nconnection with scripting_disabled=true cannot be attached.\n\nsystem: pass it only when the user named the SAP system, as 'DEV' or\n'DEV/100' (system/client). One open session on it is attached; several,\nor none, return an error that lists what is open. The indexes are then\nignored.\n\nWith the 'attach' confirmation point on, the user picks the session in a\ndialog unless `system` names exactly one open session. The response\nsays how it was chosen (`chosen_by`: named, dialog or index).","inputSchema":{"additionalProperties":false,"properties":{"connection_index":{"default":0,"type":"integer"},"session_index":{"default":0,"type":"integer"},"system":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"type":"object"},"name":"sap_connect_existing","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Connect Existing"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all open SAP connections and sessions.\n\nCovers SAP Logon plus SAP Business Client / embedded SAP GUI sessions\n(`host`: saplogon | sapguiserver). A connection with no sessions and\n`scripting_disabled: true` means the server parameter sapgui/user_scripting\nis off, so no session can be read. Each session has its system, client,\nuser, transaction, `session_number` (the \"(2)\" in \"DEV(2)\") and window\n`title`.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_list_connections","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap List Connections"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get information about the current SAP session (system, client, user, transaction, screen).\n\nAlso the SAP GUI release (sap_gui_version) and scripting_read_only: when\ntrue, the SAP server allows read-only scripting and write tools refuse.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_session_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Session Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Execute (start/run) an SAP transaction code (tcode), e.g. MM03, VA01, SM30.\n\nNavigates to the transaction's initial screen. Always check the\nscreen info in the response to understand what screen you landed on.\nSome transactions require /n prefix for SCWM (e.g., /n/SCWM/MON).\nA bare /n leaves the current transaction (unsaved data is lost).\n\nSubject to transaction blocklist/allowlist. Use sap_get_session_info\nto see the current transaction before navigating away.","inputSchema":{"additionalProperties":false,"properties":{"tcode":{"type":"string"}},"required":["tcode"],"type":"object"},"name":"sap_execute_transaction","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Execute Transaction"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press a keyboard key / function key in the SAP window (sendVKey).\n\nCommon keys: Enter (confirm), F1 (Help), F3 (Back), F4 (search help /\nvalue help), F5 (Refresh), F8 (Execute), F11 (Save), F12 (Cancel/Escape).\nAlso supports Shift+F1..F9 and Ctrl+F, Ctrl+G, Ctrl+P.\n\nA key that is not active on the screen is not sent: the response has an\nerror and available_keys, the keys this screen accepts.\n\nF11 / Save requires user confirmation via elicitation before proceeding;\nthe response then has confirmed_by_user: true. A declined save\nreturns status 'cancelled' with an error.","inputSchema":{"additionalProperties":false,"properties":{"key":{"enum":["Enter","F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12","Back","Save","Cancel","Execute","Refresh","Shift+F1","Shift+F2","Shift+F3","Shift+F4","Shift+F5","Shift+F6","Shift+F7","Shift+F8","Shift+F9","Ctrl+F","Ctrl+G","Ctrl+P"],"type":"string"}},"required":["key"],"type":"object"},"name":"sap_send_key","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Send Key"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get current SAP screen info: transaction, program, screen number, window\ntitle, and status bar message (success/error/warning text).\n\nReads from ``session.ActiveWindow`` so the response always reflects\nwhat the user sees.  The ``active_window`` field tells you which\nwindow is in focus (e.g. ``wnd[0]`` for the main screen, ``wnd[1]``\nfor a popup).  The ``title`` comes from the active window.\n\nEvery action tool (press_button, send_key, select_menu, etc.) returns\nthis same screen info, so you always know when a popup appears.\nUse sap_get_popup_window for full popup content (texts, buttons).\n\nPresent only when true: message_has_long_text (sap_press_button on\n'wnd[0]/sbar' opens it) and message_as_popup (the message also sits in a\npopup that must be closed first).\n\nPresent only when set: subscreens, the sub-screens on the active window\nas \"program:dynnr\", outer first (program / screen_number name only the\nmain screen, so an RF step, a tab page or a detail area that changes\nshows only here), and cursor, the ID of the field the cursor is in. A\nscreen redisplayed without a message, e.g. for an empty required\nfield, still moves the cursor to that field.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_screen_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Screen Info"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read the value of a field on the current SAP screen.\n\nReturns value, type, changeable status, and labels (left/right).\nFor a dropdown, value is the selected entry's text and key its key.\nFor a radio button or checkbox, value is its label and selected says\nwhether it is selected.\nUse sap_get_screen_elements to discover field IDs on unknown screens.","inputSchema":{"additionalProperties":false,"properties":{"field_id":{"type":"string"}},"required":["field_id"],"type":"object"},"name":"sap_read_field","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Field"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set (type/enter) a value into an input field on the current SAP screen.\n\nWorks on GuiTextField and GuiCTextField input fields, and on dropdowns\n(GuiComboBox, ID prefix cmb): there value picks the entry by its key or\nits text, and the response reports the key and text selected. For\nfilling in multiple fields of a form at once, use sap_set_batch_fields\ninstead. After setting a field, you may need to press Enter to trigger\nvalidation.\n\nA value longer than the field (MaxLength) or a field that is not\nchangeable is refused before writing: status 'rejected' and an error\nthat says which, and the field keeps its content.","inputSchema":{"additionalProperties":false,"properties":{"field_id":{"type":"string"},"value":{"type":"string"}},"required":["field_id","value"],"type":"object"},"name":"sap_set_field","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Field"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press (click) a pushbutton or toolbar button on the current SAP screen.\n\nReturns screen info after the press so you can detect navigation or popups.\nUse sap_get_toolbar_buttons to discover toolbar button IDs.\nUse sap_get_screen_elements to find on-screen button IDs.\nWhen screen info has message_has_long_text, pressing 'wnd[0]/sbar' opens\nthat long text (Diagnosis / Procedure), usually as a list popup: read it\nwith sap_read_list(window_id='wnd[1]').\n\nA popup button is checked like sap_handle_popup's press: a press that\nmay save, or any answer but Cancel to a popup question the tool cannot\nread, asks the user first (confirmed_by_user: true when accepted).","inputSchema":{"additionalProperties":false,"properties":{"button_id":{"type":"string"}},"required":["button_id"],"type":"object"},"name":"sap_press_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a menu item from the menu bar or a submenu.\n\nExample: 'wnd[0]/mbar/menu[1]/menu[0]'.\nUse sap_get_screen_elements on 'wnd[0]/mbar' to discover menu structure.\nReturns screen info after selection so you can detect navigation.","inputSchema":{"additionalProperties":false,"properties":{"menu_id":{"type":"string"}},"required":["menu_id"],"type":"object"},"name":"sap_select_menu","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Menu"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select or deselect a checkbox on the current SAP screen.\n\nSet selected=false to uncheck. Use sap_get_screen_elements with\ntype_filter='GuiCheckBox' to find checkbox IDs.","inputSchema":{"additionalProperties":false,"properties":{"checkbox_id":{"type":"string"},"selected":{"default":true,"type":"boolean"}},"required":["checkbox_id"],"type":"object"},"name":"sap_select_checkbox","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Checkbox"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a radio button on the current SAP screen.\n\nUse sap_get_screen_elements with type_filter='GuiRadioButton'\nto find radio button IDs on the current screen.","inputSchema":{"additionalProperties":false,"properties":{"radio_id":{"type":"string"}},"required":["radio_id"],"type":"object"},"name":"sap_select_radio_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Radio Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select an entry in a combobox/dropdown by its key or display value text.\n\nAccepts either the technical key or the visible display text.\nUse sap_get_combobox_entries first to see all valid options.\nF4 opens nothing on a dropdown; sap_set_field selects entries the same\nway.","inputSchema":{"additionalProperties":false,"properties":{"combobox_id":{"type":"string"},"key_or_value":{"type":"string"}},"required":["combobox_id","key_or_value"],"type":"object"},"name":"sap_select_combobox_entry","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Combobox Entry"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a tab in a tab strip control.\n\nReturns screen info after selection (tab content changes).\nTab IDs typically look like 'wnd[0]/usr/tabsTABSTRIP/tabpTAB01'.","inputSchema":{"additionalProperties":false,"properties":{"tab_id":{"type":"string"}},"required":["tab_id"],"type":"object"},"name":"sap_select_tab","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Tab"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all entries in a combobox/dropdown.\n\nReturns key-value pairs so you know which values are valid.","inputSchema":{"additionalProperties":false,"properties":{"combobox_id":{"type":"string"}},"required":["combobox_id"],"type":"object"},"name":"sap_get_combobox_entries","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Combobox Entries"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Fill in multiple input fields at once (dict of field_id to value).\n\nUse this to fill a form or selection screen in one call — more\nefficient than repeated sap_set_field calls. Table-control cells work\ntoo: take the cell_id template of each column from\nsap_read_table(columns_only=true) and replace {row}. A dropdown (cmb)\ntakes an entry's key or text, as in sap_set_field.\n\nThe result gives counts; `results` lists only the fields that did NOT\nsucceed (all of them with verbose=true). Check failed == 0: a field\nthat was not set does not stop the others. With --strict-errors such a\nbatch is returned as an error.","inputSchema":{"additionalProperties":false,"properties":{"fields":{"additionalProperties":true,"description":"Dict mapping field_id -> value.","type":"object"},"skip_readonly":{"default":false,"description":"Silently skip fields whose element reports\nChangeable == False instead of counting them as failures.","type":"boolean"},"validate":{"default":false,"description":"Press Enter after setting fields and return status-bar\nfeedback. Skipped when no fields were actually set, and when\nany field failed (`failed` > 0) unless validate_partial=true.\n`validation.performed` is false when Enter was not pressed or\nSAP refused it (then with `error`).","type":"boolean"},"validate_partial":{"default":false,"description":"With validate=true, press Enter even when some\nfields failed.","type":"boolean"},"verbose":{"default":false,"description":"List every field in `results`, not only the failures.","type":"boolean"}},"required":["fields"],"type":"object"},"name":"sap_set_batch_fields","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Batch Fields"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read the content of a multiline text editor (GuiTextedit) —\nlong texts, notes, comments, document text.\n\nReturns full text and line count. Use max_lines to cap output for\nlarge text editors (0 = all lines).","inputSchema":{"additionalProperties":false,"properties":{"max_lines":{"default":0,"type":"integer"},"textedit_id":{"type":"string"}},"required":["textedit_id"],"type":"object"},"name":"sap_read_textedit","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Textedit"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Write text into a multiline text editor (GuiTextedit) —\nlong texts, notes, comments, document text.","inputSchema":{"additionalProperties":false,"properties":{"text":{"type":"string"},"textedit_id":{"type":"string"}},"required":["textedit_id","text"],"type":"object"},"name":"sap_set_textedit","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Textedit"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set focus to any screen element by its ID.\n\nSome SAP actions require focus on a specific element before they work\n(e.g., F4 search help on a field). Use this to set focus before\nsending keys with sap_send_key.","inputSchema":{"additionalProperties":false,"properties":{"element_id":{"type":"string"}},"required":["element_id"],"type":"object"},"name":"sap_set_focus","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Focus"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read rows from a table on the current screen — ALV grid (report/list\noutput) or TableControl (SM30 maintenance view, customizing screens).\n\nAuto-detects the table type. The response includes a 'table_type' field\n('GuiGridView' for ALV or 'GuiTableControl') so you know which\ntype-specific tools to use next (e.g., sap_get_alv_toolbar for ALV,\nsap_scroll_table_control for TableControl).\n\nUse columns_only=true for schema discovery (returns column metadata\nonly, no data). For a TableControl it also gives each column's cell_type\nand a cell_id template ({row} = zero-based visible row) for\nsap_set_batch_fields. Use columns to fetch only specific columns (CSV).\nUse start_row to paginate through large tables. On a TableControl a\nstart_row (0 included) scrolls there first; without one the read starts\nwhere the table is scrolled now (e.g. after Position...).\nfirst_visible_row says which row is on top.\n\nA TableControl read returns at most the visible rows: page with\nstart_row=next_start_row while has_more is true. start_row_note\nexplains a clamped or failed scroll. total_rows counts its empty lines\ntoo (SM30 pads the view). When the read reaches the first empty row,\nthe response has empty_rows_from, that row's absolute index: the data\nends there.","inputSchema":{"additionalProperties":false,"properties":{"columns":{"default":"","type":"string"},"columns_only":{"default":false,"type":"boolean"},"max_rows":{"default":100,"type":"integer"},"start_row":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_read_table","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Table"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get all toolbar buttons from an ALV grid.\n\nReturns button IDs, texts, and types. Use this to discover available\nactions (sort, filter, export, etc.) before pressing them with\nsap_press_alv_toolbar_button. Only works on GuiGridView (ALV),\nnot GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_get_alv_toolbar","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Alv Toolbar"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press a toolbar button on an ALV grid (e.g., sort, filter, export).\n\nUse sap_get_alv_toolbar to find button IDs. A menu button (Menu /\nButtonAndMenu) opens its menu and the response lists menu_items (text and\nfunction_code); pick one with sap_select_alv_context_menu_item.","inputSchema":{"additionalProperties":false,"properties":{"button_id":{"type":"string"},"grid_id":{"type":"string"}},"required":["grid_id","button_id"],"type":"object"},"name":"sap_press_alv_toolbar_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Alv Toolbar Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select an item from an opened ALV context menu.\n\nFirst use sap_press_alv_toolbar_button on a Menu button to open it,\nthen use this to select an item. Alternatively, pass toolbar_button_id\nto open the menu and select in one atomic call (recommended).\n\n`menu_item_id` can be a technical function code (for example `@M00006`),\nvisible menu text (for example `Confirm WT in Foreground`), or a position\ndescriptor. You can pass human-readable menu text directly. The\nmenu_items of sap_press_alv_toolbar_button list what a menu offers.\n\n`select_by` controls how selection is performed:\n- `auto` (default): heuristic based on whether `menu_item_id` has spaces\n- `id`: function code\n- `text`: visible menu text\n- `position`: position descriptor","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"},"menu_item_id":{"type":"string"},"select_by":{"default":"auto","enum":["auto","id","text","position"],"type":"string"},"toolbar_button_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"required":["grid_id","menu_item_id"],"type":"object"},"name":"sap_select_alv_context_menu_item","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Alv Context Menu Item"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a row in a table/grid.\n\nWorks on both ALV grids and table controls. Row index is zero-based.\nFor ALV: uses absolute row index. For TableControl: scrolls to make\nthe row visible first if needed.","inputSchema":{"additionalProperties":false,"properties":{"row":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","row"],"type":"object"},"name":"sap_select_table_row","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Table Row"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a cell in a table/grid (often opens details or drills down).\n\nRow is zero-based. Column is the column name (from sap_read_table\nor sap_get_column_info). Works on both ALV and TableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"row":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","row","column"],"type":"object"},"name":"sap_double_click_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Modify the value of a cell in an ALV grid or table control.\n\nOnly works on editable cells. Use sap_get_cell_info to check if\na cell is changeable before attempting to modify it.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"},"value":{"type":"string"}},"required":["grid_id","row","column","value"],"type":"object"},"name":"sap_modify_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Modify Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set the current (focused) cell in an ALV grid or table control.\n\nUseful before pressing toolbar buttons that act on the current cell.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"}},"required":["grid_id","row","column"],"type":"object"},"name":"sap_set_current_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Current Cell"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get detailed column info from an ALV grid or table control.\n\nReturns column names, titles and tooltips; for an ALV grid also each\ncolumn's data_type (string, date, decimal, ...) and key flag, for a table\ncontrol each column's cell_type and cell_id template. For a lighter\nalternative, use sap_read_table with columns_only=true.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_get_column_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Column Info"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get the currently focused cell position in an ALV grid or table control.","inputSchema":{"additionalProperties":false,"properties":{"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_get_current_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Current Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Scroll a GuiTableControl to a specific row position.\n\nDoes NOT work on ALV grids (they handle scrolling internally).\nFor reading data at a specific offset, prefer sap_read_table with\nstart_row parameter — it handles scrolling automatically.\n\nposition in the response is the row SAP actually put at the top, which\ncan differ from the one asked for (then requested_position and a note\nsay so). Cell IDs ([col,row]) count visible rows from that row.","inputSchema":{"additionalProperties":false,"properties":{"position":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","position"],"type":"object"},"name":"sap_scroll_table_control","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Scroll Table Control"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get row metadata (selectable, selected) from a GuiTableControl.\n\nIf rows is omitted, queries all visible rows.\nDoes NOT work on ALV grids.","inputSchema":{"additionalProperties":false,"properties":{"rows":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"default":null},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_get_table_control_row_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Table Control Row Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select or deselect all columns in a GuiTableControl. Does NOT work on ALV grids.","inputSchema":{"additionalProperties":false,"properties":{"select":{"default":true,"type":"boolean"},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_select_all_table_control_columns","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select All Table Control Columns"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get detailed cell metadata from an ALV grid.\n\nReturns value, changeable, cell_type (Normal, CheckBox, ValueList,\nButton, ...), state (Normal, Error, Warning, Info: why a cell was\nrejected), f4_help, hotspot, color, tooltip, max_length; plus checked\nfor a checkbox and list_box_count (entries) for a dropdown cell.\nDoes NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"}},"required":["grid_id","row","column"],"type":"object"},"name":"sap_get_cell_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Cell Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Click a column header in an ALV grid (triggers sort). Does NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"}},"required":["grid_id","column"],"type":"object"},"name":"sap_press_column_header","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Column Header"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select all rows in an ALV grid. Does NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_select_all_rows","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select All Rows"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select multiple rows at once in an ALV grid or table control.\n\nPass a list of row indices (e.g., [0, 2, 5]).","inputSchema":{"additionalProperties":false,"properties":{"rows":{"items":{"type":"integer"},"type":"array"},"table_id":{"type":"string"}},"required":["table_id","rows"],"type":"object"},"name":"sap_select_multiple_rows","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Multiple Rows"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Check if a popup/modal dialog is open (wnd[1], wnd[2], etc.).\n\nReturns the popup's title, text content, and available buttons so\nyou know how to respond. Also classifies the popup and suggests a\nsafe next action. Returns {popup_exists: false} if no popup.\n\nThe popup's text is in `texts`: labels and display-only fields (a\nmessage popup's lines). A popup whose body is a classic list (an F4\nhit list, a note, a message's long text) has `list` (`cells`, `rows`,\n`hint`) instead: its lines are never in `texts` or\n`interactive_elements`; read them with sap_read_list. Radio buttons\nand checkboxes in interactive_elements carry selected. `texts`,\n`buttons` and `interactive_elements` are left out when empty.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_popup_window","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Popup Window"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Read and optionally act on the current popup/modal dialog.\n\nUse when active_window shows wnd[1] or higher. Combines popup\ninspection and response in a single call.\n\nActions:\n- read: return popup content without acting (default)\n- confirm: press OK/Yes/Continue/Enter on the popup\n- cancel: press Cancel (or F12) on the popup; never No, which on a\n  save prompt drops the changes\n- press: press a specific button by its text or tooltip\n- auto: take only a clearly safe action; otherwise return the popup read-only\n\nA press that may save (a Save button, or Yes/OK on a popup about saving,\ne.g. \"Save the changes first?\") asks the user first, like F11 in\nsap_send_key. So does any answer but Cancel when the popup's question\ncannot be read (question_readable: false; SAP GUI's Edge browser\ncontrol). On such a popup, confirm never falls back to Enter, and auto\nonly reads. An accepted press reports confirmed_by_user: true.\n\nReturns the popup contents plus classification, requested action,\nand post-action screen/popup state when something was pressed.","inputSchema":{"additionalProperties":false,"properties":{"action":{"default":"read","enum":["read","confirm","cancel","press","auto"],"type":"string"},"button_text":{"default":"","type":"string"}},"type":"object"},"name":"sap_handle_popup","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Handle Popup"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all buttons on the system toolbar (tbar[0]) and app toolbar (tbar[1]).\n\nReturns button IDs, text, tooltip, and enabled state. This is for\nstandard SAP toolbars, NOT ALV (use sap_get_alv_toolbar for ALV).","inputSchema":{"additionalProperties":false,"properties":{"window_id":{"default":"wnd[0]","type":"string"}},"type":"object"},"name":"sap_get_toolbar_buttons","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Toolbar Buttons"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read content from a GuiShell subtype (e.g., HTMLViewer).\n\nAn HTML viewer's page text and URL are readable only with the Internet\nExplorer browser control; with the Edge control (SAP GUI 7.70+ default,\ne.g. the F1 Performance Assistant) the response says so in `note`.\nUse sap_get_screen_elements first to find shell element IDs.","inputSchema":{"additionalProperties":false,"properties":{"shell_id":{"type":"string"}},"required":["shell_id"],"type":"object"},"name":"sap_read_shell_content","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Shell Content"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read a classic ABAP list (WRITE output of a report) as lines of text.\n\nUse it when a report shows a plain list rather than an ALV grid (program\nSAPMSSY0, screen 120), and for F4 hit lists in a popup (window_id=\n'wnd[1]'). Such a list has no table object: every word is its own label,\nso sap_get_screen_elements leaves the cells out and reports it under\n'lists'. This returns the page as the lines the user sees, with no\nscreenshot needed.\n\n- colors: rows whose text has a semantic list colour, e.g. 'negative'\n  (red, errors), 'positive' (green), 'total', 'heading'\n- scroll: present when the list is longer than the page; pass\n  scroll_to=position+page_size to read the next page\n- with_ids=true adds the ID of each line's first label, to set the focus\n  on a line (sap_set_focus) before F2 / double-click\n- is_list=false means this screen has no list: use sap_read_table","inputSchema":{"additionalProperties":false,"properties":{"max_lines":{"default":200,"type":"integer"},"scroll_to":{"default":-1,"type":"integer"},"window_id":{"default":"wnd[0]","type":"string"},"with_ids":{"default":false,"type":"boolean"}},"type":"object"},"name":"sap_read_list","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read List"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read data from a tree control (TableTreeControl, ColumnTreeControl, etc.).\n\nReturns node hierarchy with texts and column values. For large trees\n(e.g., SPRO with 1000+ nodes), use sap_get_tree_node_children for\nstep-by-step navigation instead. Use sap_search_tree_nodes to find\nspecific nodes by text.\n\ntotal_nodes is the number of nodes read; truncated=true means the tree\nhas more loaded nodes (available_nodes) than max_nodes allowed.","inputSchema":{"additionalProperties":false,"properties":{"max_nodes":{"default":200,"type":"integer"},"tree_id":{"type":"string"}},"required":["tree_id"],"type":"object"},"name":"sap_read_tree","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Tree"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Expand a folder node in a tree control to reveal its children.\n\nAfter expanding, use sap_get_tree_node_children or sap_read_tree\nto see the newly visible child nodes.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_expand_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Expand Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Collapse a folder node in a tree control (e.g. SPRO/customizing tree).","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_collapse_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Collapse Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a node in a tree control.\n\nHighlights the node without opening it. For SPRO-style trees,\nuse sap_click_tree_link on the execute icon column instead.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_select_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a node in a tree control (often opens details or drills down).\n\nIn SPRO/customizing trees, this may open documentation (hypertext)\nrather than executing the activity. Use sap_click_tree_link on the\nexecute column (typically column '2') for SPRO activities.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_double_click_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a specific item (column cell) in a tree node row.\n\nitem_name is the column name (e.g., 'Column1', 'Column2').\nUse sap_read_tree to discover column names for the tree.","inputSchema":{"additionalProperties":false,"properties":{"item_name":{"type":"string"},"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key","item_name"],"type":"object"},"name":"sap_double_click_tree_item","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Tree Item"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Click a hyperlink in a tree node item.\n\nFor SPRO/customizing trees, click on the execute icon column\n(typically item_name='2') to run an activity. Use sap_read_tree\nto see which columns have link-type items.","inputSchema":{"additionalProperties":false,"properties":{"item_name":{"type":"string"},"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key","item_name"],"type":"object"},"name":"sap_click_tree_link","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Click Tree Link"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Find a tree node key by its path.\n\nE.g., '2\\1\\2' = 2nd child of root, then 1st child, then 2nd.","inputSchema":{"additionalProperties":false,"properties":{"path":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","path"],"type":"object"},"name":"sap_find_tree_node_by_path","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Find Tree Node By Path"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Search for tree nodes by text. Returns matches with full ancestor paths.\n\nUseful for finding nodes in deep trees where the same label appears\nin multiple branches. Case-insensitive substring match.\nOptionally pass column to search in a specific column instead of node text.\n\n**Important limitation**: Only searches nodes that are already loaded\n(expanded) in the tree. Collapsed subtrees are not searched. If you\ndon't find what you expect, expand parent nodes first using\nsap_get_tree_node_children with expand=true, then search again.\n\ntotal_matches counts the matches returned. stopped_early=true means the\nsearch reached max_results before the last loaded node, so more\nmatches are possible.","inputSchema":{"additionalProperties":false,"properties":{"column":{"default":"","type":"string"},"max_results":{"default":20,"type":"integer"},"search_text":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","search_text"],"type":"object"},"name":"sap_search_tree_nodes","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Search Tree Nodes"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Get direct children of a tree node. Much faster than read_tree for\nstep-by-step navigation of deep trees (e.g., SPRO).\n\nOmit node_key or pass empty string for root-level nodes.\nSet expand=true to expand the node first (requires write permission).","inputSchema":{"additionalProperties":false,"properties":{"expand":{"default":false,"type":"boolean"},"node_key":{"default":"","type":"string"},"tree_id":{"type":"string"}},"required":["tree_id"],"type":"object"},"name":"sap_get_tree_node_children","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Tree Node Children"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Discover all elements on the current SAP screen.\n\nUseful for finding field IDs when working with a new screen.\n\nUse type_filter and changeable_only to reduce response size on\ncomplex screens (e.g. type_filter=\"GuiTextField,GuiCTextField\"\nto find only input fields).\n\nmax_depth controls how deep to recurse into containers (default 2).\nUse max_depth=1 for a quick overview, max_depth=3+ for deeply nested\nlayouts (splitter containers, tab strips with sub-containers).\n\nPass container_id='wnd[0]/mbar' to discover the menu bar structure.\n\nRadio buttons and checkboxes report selected (true/false); a dropdown\nreports its selected key.\n\nA table control (SM30-style) is ONE element here, not one per cell: use\nsap_read_table(columns_only=true) for its columns and cell_id templates.\nA classic list (report WRITE output, SE16 standard list, F4 hit list) is\nleft out and reported under 'lists': read it with sap_read_list.\nexpand_tables=true lists every visible cell of both (large).\n\nDocking containers sit BESIDE the user area, not inside it: the\ndialog-structure tree of a view cluster (SM34, most IMG activities) and\nthe SE80 tree are under 'wnd[0]/shellcont'. When the window has any, the\nresponse lists them as docking_containers; discover them with that id,\nor pass container_id='wnd[0]' (max_depth=1) for all top-level areas.","inputSchema":{"additionalProperties":false,"properties":{"changeable_only":{"default":false,"type":"boolean"},"container_id":{"default":"wnd[0]/usr","type":"string"},"expand_tables":{"default":false,"type":"boolean"},"max_depth":{"default":2,"type":"integer"},"type_filter":{"default":"","type":"string"}},"type":"object"},"name":"sap_get_screen_elements","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Screen Elements"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Take a screenshot of the current SAP window.\n\nUse as a fallback when structured tools (sap_get_screen_elements,\nsap_read_field, sap_read_table) return empty or confusing results,\ne.g., on Web Dynpro screens where the element tree is non-standard.\n\nTo put a screenshot into a document, pass save_path (must end in .png,\ndirectory must exist, existing files are never overwritten). The file\nkeeps SAP GUI's full resolution; the inline image is capped at 1920px.\nThe response then also reports the absolute path and pixel size. Set\ninline=False to skip the image when only the file is needed.","inputSchema":{"additionalProperties":false,"properties":{"inline":{"default":true,"type":"boolean"},"save_path":{"default":"","type":"string"}},"type":"object"},"name":"sap_screenshot","title":"Sap Screenshot"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Render a preview card of the current SAP screen for the user:\nscreenshot, session/transaction info, status bar, and the values the\nagent is about to write (pending_fields). Call before significant\nwrites (batch fills, F11 save) or whenever the user asks to see\nwhat's about to happen. Read-only: nothing is written or saved.","inputSchema":{"additionalProperties":false,"properties":{"include_screenshot":{"default":true,"type":"boolean"},"note":{"default":"","type":"string"},"pending_fields":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"default":null}},"type":"object"},"name":"sap_preview","title":"Sap Preview"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Choose which SAP operations need the user's explicit approval first.\n\nReplaces this session's set of confirmation points. When a point is\nactive, every matching tool call pauses and asks the user to approve it\n(MCP elicitation) before anything reaches SAP; declining returns an error\nand nothing is executed.\n\nPoints:\n- transactions: sap_execute_transaction\n- batch_fields: sap_set_batch_fields\n- field_writes: sap_set_field, sap_modify_cell, sap_set_textedit,\n  sap_select_checkbox, sap_select_radio_button, sap_select_combobox_entry\n- all_writes: every write-tagged tool. Strict and noisy — many write tools\n  only select, scroll or navigate, and they will all prompt. Under\n  all_writes, sap_send_key(\"F11\") asks twice: once for the category and\n  once for the unchanged save gate.\n- attach: sap_connect_existing lets the user pick the SAP session in a\n  dialog, unless the call names a system with exactly one open session.\n\n'save' (F11 / Save key, Save toolbar button) is always on and cannot be\nturned off. Points set by the server's --confirm flag cannot be removed\neither. Adding a point is silent; *removing* one asks the user first, and\na declined removal keeps the point.\n\nConfirmation prompts block until the user answers, and on clients without\nelicitation support the gated call fails instead of running unconfirmed\n(same fail-closed rule as the save gate). On such a client points also\ncannot be removed, so activating one there blocks that whole category for\nthe rest of the session. Call sap_preview before a gated action so the\nuser can see the screen and pending values first.","inputSchema":{"additionalProperties":false,"properties":{"points":{"items":{"enum":["batch_fields","field_writes","transactions","all_writes","attach"],"type":"string"},"type":"array"}},"required":["points"],"type":"object"},"name":"sap_set_confirmation_points","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Confirmation Points"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Return step-by-step guidance for a common SAP workflow.\n\nAvailable workflows:\n- **search_help**: F4 search help on a field. `target` = field ID.\n- **table_export**: Paginated table export. `target` = table element ID.\n- **spro_navigate**: SPRO customizing navigation. `target` = activity name.","inputSchema":{"additionalProperties":false,"properties":{"target":{"type":"string"},"workflow":{"enum":["search_help","table_export","spro_navigate"],"type":"string"}},"required":["workflow","target"],"type":"object"},"name":"sap_get_workflow_guide","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Workflow Guide"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Return a generic, read-first guide for a supported SAP transaction.\n\nAvailable transactions:\n- **/SCWM/MON**: EWM Warehouse Monitor with tree navigation and ALV results.\n- **SM30**: table/view maintenance and view clusters (SM34) - also what\n  most IMG activities open: reading the table, the docked dialog-structure\n  tree, new entries, saving and the customizing request prompt.\n\nAliases accepted: `SCWM/MON`, `warehouse monitor`, `ewm warehouse monitor`,\n`SM34`, `table maintenance`, `view maintenance`, `view cluster`.","inputSchema":{"additionalProperties":false,"properties":{"task":{"default":"","type":"string"},"transaction":{"type":"string"}},"required":["transaction"],"type":"object"},"name":"sap_get_transaction_guide","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Transaction Guide"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":true,"readOnlyHint":false},"description":"Disconnect from the current SAP session and release the binding.\n\nCloses only the sessions this MCP session opened: the one sap_connect\nlogged on in and any /o window opened from it. Sessions that were\nattached (via sap_connect_existing), and /o windows opened from them, are\ndetached but left open so the user can continue working manually.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_disconnect","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Disconnect"}],"ttlMs":0}}}
{"at":"2026-11-23T00:01:41.592Z","dir":"sent","era":"initialize","message":{"id":1,"jsonrpc":"2.0","method":"initialize","params":{"capabilities":{},"clientInfo":{"name":"didrun-lab","version":"0.1.0"},"protocolVersion":"2025-11-25"}}}
{"at":"2026-11-23T00:01:43.139Z","dir":"received","era":"initialize","message":{"id":1,"jsonrpc":"2.0","result":{"capabilities":{"logging":{},"prompts":{"listChanged":true},"resources":{"listChanged":true,"subscribe":false},"tools":{"listChanged":true}},"instructions":"SAP GUI automation server. Controls SAP GUI for Windows via COM scripting.\n\n## Rules (read first)\n\n- **Never guess element IDs.** Discover them on every new screen (`sap_get_screen_elements`, `sap_get_toolbar_buttons`): IDs differ between systems and customizations.\n- **Check `screen.active_window` after every action.** `wnd[1]` or higher is a popup: read it with `sap_get_popup_window` before you go on.\n- **Confirmations.** F11 / Save always asks the user first; `sap_set_confirmation_points` can add `transactions`, `batch_fields`, `field_writes`, `all_writes` and `attach`. A \"declined\" error means the user said no: do not retry the call or reach its result another way. Tell the user and wait for their next instruction. Offer `sap_preview` before significant writes (batch fills, Save) so the user sees the screen and the pending values.\n\n## Getting Started\n\n1. SAP already logged on: `sap_connect_existing`; pass `system` (e.g. 'DEV') when the user named the system. SAP Business Client sessions work too (experimental).\n2. SAP not open: `sap_connect` with the SAP Logon entry.\n3. `sap_get_session_info` shows the current transaction and screen.\n\n## Screen Discovery\n\n`sap_get_screen_elements` with `type_filter` (e.g. \"GuiTextField,GuiCTextField\") and `changeable_only=true` keeps the output small; `sap_read_field` reads one field. A tree docked beside the screen (SM34 view clusters, IMG activities) is not under `wnd[0]/usr`: discovery lists it under `docking_containers` (e.g. `wnd[0]/shellcont`).\n\n## Popup Handling\n\nPopups often follow button presses, Enter, F8 and double-clicks. `sap_get_popup_window` gives the text, the buttons, a classification and a safe next step; `sap_handle_popup` acts on it.\n\n## Tables\n\n`sap_read_table` detects the type (`table_type`). Start with `columns_only=true`, then fetch only `columns=\"COL_A,COL_B\"`.\n- ALV grid (reports): page with `start_row` until `total_rows`; its toolbar is `sap_get_alv_toolbar`.\n- Table control (SM30, SPRO): one read returns the visible rows; page with `start_row=next_start_row` while `has_more` is true. `total_rows` counts empty lines; `empty_rows_from` is where the data ends. To jump to an entry use the \"Position...\" toolbar button, not manual scrolling.\n\n## SPRO and Trees\n\nNever `sap_read_tree` SPRO (1000+ nodes). `sap_search_tree_nodes` searches expanded nodes only: expand parents with `sap_get_tree_node_children(expand=true)`. Run an activity with `sap_click_tree_link(tree_id, node_key, \"2\")`; a double-click opens its documentation. In a view cluster (SM34) use `double_click_tree_item` with the column name (usually \"Column1\").\n\n## Keys and Common Mistakes\n\nEnter confirms, F3 goes back, F8 executes, F11 saves, F12 cancels. F4 is value help on the focused field (`sap_set_focus` first): the popup's classification says what opened (`list`, `date_picker`, `time_picker`, `input_required`), and `sap_get_workflow_guide(\"search_help\", field_id)` covers each. Dropdowns (`cmb`) have no F4: `sap_set_field` takes the entry's key or text. In table maintenance F5 means \"New Entries\", not refresh: check the toolbar tooltips first.\n","protocolVersion":"2025-11-25","serverInfo":{"name":"mcp-sap-gui","version":"0.6.0"}}}}
{"at":"2026-11-23T00:01:43.139Z","dir":"sent","era":"initialize","message":{"jsonrpc":"2.0","method":"notifications/initialized"}}
{"at":"2026-11-23T00:01:43.139Z","dir":"sent","era":"initialize","message":{"id":2,"jsonrpc":"2.0","method":"tools/list","params":{}}}
{"at":"2026-11-23T00:01:43.328Z","dir":"received","era":"initialize","message":{"id":2,"jsonrpc":"2.0","result":{"tools":[{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Connect to an SAP system by its name in SAP Logon Pad.\n\nCredentials are resolved from a .env file (SAP_USER, SAP_PASSWORD,\nSAP_CLIENT, SAP_LANGUAGE) so passwords never appear in MCP tool calls.\nParameters provided here override the .env values (except password).\nIf SAP is already open and logged in, use sap_connect_existing instead.","inputSchema":{"additionalProperties":false,"properties":{"client":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null},"system_description":{"type":"string"},"user":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"required":["system_description"],"type":"object"},"name":"sap_connect","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Connect"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Connect to an already open SAP session. Use this when SAP is already logged in.\n\nThis is the most common starting point. connection_index=0 and session_index=0\nconnect to the first open session. Also attaches to SAP Business Client /\nembedded SAP GUI sessions. Indexes come from sap_list_connections; a\nconnection with scripting_disabled=true cannot be attached.\n\nsystem: pass it only when the user named the SAP system, as 'DEV' or\n'DEV/100' (system/client). One open session on it is attached; several,\nor none, return an error that lists what is open. The indexes are then\nignored.\n\nWith the 'attach' confirmation point on, the user picks the session in a\ndialog unless `system` names exactly one open session. The response\nsays how it was chosen (`chosen_by`: named, dialog or index).","inputSchema":{"additionalProperties":false,"properties":{"connection_index":{"default":0,"type":"integer"},"session_index":{"default":0,"type":"integer"},"system":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"type":"object"},"name":"sap_connect_existing","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Connect Existing"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all open SAP connections and sessions.\n\nCovers SAP Logon plus SAP Business Client / embedded SAP GUI sessions\n(`host`: saplogon | sapguiserver). A connection with no sessions and\n`scripting_disabled: true` means the server parameter sapgui/user_scripting\nis off, so no session can be read. Each session has its system, client,\nuser, transaction, `session_number` (the \"(2)\" in \"DEV(2)\") and window\n`title`.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_list_connections","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap List Connections"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get information about the current SAP session (system, client, user, transaction, screen).\n\nAlso the SAP GUI release (sap_gui_version) and scripting_read_only: when\ntrue, the SAP server allows read-only scripting and write tools refuse.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_session_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Session Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Execute (start/run) an SAP transaction code (tcode), e.g. MM03, VA01, SM30.\n\nNavigates to the transaction's initial screen. Always check the\nscreen info in the response to understand what screen you landed on.\nSome transactions require /n prefix for SCWM (e.g., /n/SCWM/MON).\nA bare /n leaves the current transaction (unsaved data is lost).\n\nSubject to transaction blocklist/allowlist. Use sap_get_session_info\nto see the current transaction before navigating away.","inputSchema":{"additionalProperties":false,"properties":{"tcode":{"type":"string"}},"required":["tcode"],"type":"object"},"name":"sap_execute_transaction","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Execute Transaction"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press a keyboard key / function key in the SAP window (sendVKey).\n\nCommon keys: Enter (confirm), F1 (Help), F3 (Back), F4 (search help /\nvalue help), F5 (Refresh), F8 (Execute), F11 (Save), F12 (Cancel/Escape).\nAlso supports Shift+F1..F9 and Ctrl+F, Ctrl+G, Ctrl+P.\n\nA key that is not active on the screen is not sent: the response has an\nerror and available_keys, the keys this screen accepts.\n\nF11 / Save requires user confirmation via elicitation before proceeding;\nthe response then has confirmed_by_user: true. A declined save\nreturns status 'cancelled' with an error.","inputSchema":{"additionalProperties":false,"properties":{"key":{"enum":["Enter","F1","F2","F3","F4","F5","F6","F7","F8","F9","F10","F11","F12","Back","Save","Cancel","Execute","Refresh","Shift+F1","Shift+F2","Shift+F3","Shift+F4","Shift+F5","Shift+F6","Shift+F7","Shift+F8","Shift+F9","Ctrl+F","Ctrl+G","Ctrl+P"],"type":"string"}},"required":["key"],"type":"object"},"name":"sap_send_key","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Send Key"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get current SAP screen info: transaction, program, screen number, window\ntitle, and status bar message (success/error/warning text).\n\nReads from ``session.ActiveWindow`` so the response always reflects\nwhat the user sees.  The ``active_window`` field tells you which\nwindow is in focus (e.g. ``wnd[0]`` for the main screen, ``wnd[1]``\nfor a popup).  The ``title`` comes from the active window.\n\nEvery action tool (press_button, send_key, select_menu, etc.) returns\nthis same screen info, so you always know when a popup appears.\nUse sap_get_popup_window for full popup content (texts, buttons).\n\nPresent only when true: message_has_long_text (sap_press_button on\n'wnd[0]/sbar' opens it) and message_as_popup (the message also sits in a\npopup that must be closed first).\n\nPresent only when set: subscreens, the sub-screens on the active window\nas \"program:dynnr\", outer first (program / screen_number name only the\nmain screen, so an RF step, a tab page or a detail area that changes\nshows only here), and cursor, the ID of the field the cursor is in. A\nscreen redisplayed without a message, e.g. for an empty required\nfield, still moves the cursor to that field.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_screen_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Screen Info"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read the value of a field on the current SAP screen.\n\nReturns value, type, changeable status, and labels (left/right).\nFor a dropdown, value is the selected entry's text and key its key.\nFor a radio button or checkbox, value is its label and selected says\nwhether it is selected.\nUse sap_get_screen_elements to discover field IDs on unknown screens.","inputSchema":{"additionalProperties":false,"properties":{"field_id":{"type":"string"}},"required":["field_id"],"type":"object"},"name":"sap_read_field","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Field"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set (type/enter) a value into an input field on the current SAP screen.\n\nWorks on GuiTextField and GuiCTextField input fields, and on dropdowns\n(GuiComboBox, ID prefix cmb): there value picks the entry by its key or\nits text, and the response reports the key and text selected. For\nfilling in multiple fields of a form at once, use sap_set_batch_fields\ninstead. After setting a field, you may need to press Enter to trigger\nvalidation.\n\nA value longer than the field (MaxLength) or a field that is not\nchangeable is refused before writing: status 'rejected' and an error\nthat says which, and the field keeps its content.","inputSchema":{"additionalProperties":false,"properties":{"field_id":{"type":"string"},"value":{"type":"string"}},"required":["field_id","value"],"type":"object"},"name":"sap_set_field","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Field"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press (click) a pushbutton or toolbar button on the current SAP screen.\n\nReturns screen info after the press so you can detect navigation or popups.\nUse sap_get_toolbar_buttons to discover toolbar button IDs.\nUse sap_get_screen_elements to find on-screen button IDs.\nWhen screen info has message_has_long_text, pressing 'wnd[0]/sbar' opens\nthat long text (Diagnosis / Procedure), usually as a list popup: read it\nwith sap_read_list(window_id='wnd[1]').\n\nA popup button is checked like sap_handle_popup's press: a press that\nmay save, or any answer but Cancel to a popup question the tool cannot\nread, asks the user first (confirmed_by_user: true when accepted).","inputSchema":{"additionalProperties":false,"properties":{"button_id":{"type":"string"}},"required":["button_id"],"type":"object"},"name":"sap_press_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a menu item from the menu bar or a submenu.\n\nExample: 'wnd[0]/mbar/menu[1]/menu[0]'.\nUse sap_get_screen_elements on 'wnd[0]/mbar' to discover menu structure.\nReturns screen info after selection so you can detect navigation.","inputSchema":{"additionalProperties":false,"properties":{"menu_id":{"type":"string"}},"required":["menu_id"],"type":"object"},"name":"sap_select_menu","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Menu"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select or deselect a checkbox on the current SAP screen.\n\nSet selected=false to uncheck. Use sap_get_screen_elements with\ntype_filter='GuiCheckBox' to find checkbox IDs.","inputSchema":{"additionalProperties":false,"properties":{"checkbox_id":{"type":"string"},"selected":{"default":true,"type":"boolean"}},"required":["checkbox_id"],"type":"object"},"name":"sap_select_checkbox","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Checkbox"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a radio button on the current SAP screen.\n\nUse sap_get_screen_elements with type_filter='GuiRadioButton'\nto find radio button IDs on the current screen.","inputSchema":{"additionalProperties":false,"properties":{"radio_id":{"type":"string"}},"required":["radio_id"],"type":"object"},"name":"sap_select_radio_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Radio Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select an entry in a combobox/dropdown by its key or display value text.\n\nAccepts either the technical key or the visible display text.\nUse sap_get_combobox_entries first to see all valid options.\nF4 opens nothing on a dropdown; sap_set_field selects entries the same\nway.","inputSchema":{"additionalProperties":false,"properties":{"combobox_id":{"type":"string"},"key_or_value":{"type":"string"}},"required":["combobox_id","key_or_value"],"type":"object"},"name":"sap_select_combobox_entry","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Combobox Entry"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a tab in a tab strip control.\n\nReturns screen info after selection (tab content changes).\nTab IDs typically look like 'wnd[0]/usr/tabsTABSTRIP/tabpTAB01'.","inputSchema":{"additionalProperties":false,"properties":{"tab_id":{"type":"string"}},"required":["tab_id"],"type":"object"},"name":"sap_select_tab","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Tab"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all entries in a combobox/dropdown.\n\nReturns key-value pairs so you know which values are valid.","inputSchema":{"additionalProperties":false,"properties":{"combobox_id":{"type":"string"}},"required":["combobox_id"],"type":"object"},"name":"sap_get_combobox_entries","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Combobox Entries"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Fill in multiple input fields at once (dict of field_id to value).\n\nUse this to fill a form or selection screen in one call — more\nefficient than repeated sap_set_field calls. Table-control cells work\ntoo: take the cell_id template of each column from\nsap_read_table(columns_only=true) and replace {row}. A dropdown (cmb)\ntakes an entry's key or text, as in sap_set_field.\n\nThe result gives counts; `results` lists only the fields that did NOT\nsucceed (all of them with verbose=true). Check failed == 0: a field\nthat was not set does not stop the others. With --strict-errors such a\nbatch is returned as an error.","inputSchema":{"additionalProperties":false,"properties":{"fields":{"additionalProperties":true,"description":"Dict mapping field_id -> value.","type":"object"},"skip_readonly":{"default":false,"description":"Silently skip fields whose element reports\nChangeable == False instead of counting them as failures.","type":"boolean"},"validate":{"default":false,"description":"Press Enter after setting fields and return status-bar\nfeedback. Skipped when no fields were actually set, and when\nany field failed (`failed` > 0) unless validate_partial=true.\n`validation.performed` is false when Enter was not pressed or\nSAP refused it (then with `error`).","type":"boolean"},"validate_partial":{"default":false,"description":"With validate=true, press Enter even when some\nfields failed.","type":"boolean"},"verbose":{"default":false,"description":"List every field in `results`, not only the failures.","type":"boolean"}},"required":["fields"],"type":"object"},"name":"sap_set_batch_fields","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Batch Fields"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read the content of a multiline text editor (GuiTextedit) —\nlong texts, notes, comments, document text.\n\nReturns full text and line count. Use max_lines to cap output for\nlarge text editors (0 = all lines).","inputSchema":{"additionalProperties":false,"properties":{"max_lines":{"default":0,"type":"integer"},"textedit_id":{"type":"string"}},"required":["textedit_id"],"type":"object"},"name":"sap_read_textedit","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Textedit"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Write text into a multiline text editor (GuiTextedit) —\nlong texts, notes, comments, document text.","inputSchema":{"additionalProperties":false,"properties":{"text":{"type":"string"},"textedit_id":{"type":"string"}},"required":["textedit_id","text"],"type":"object"},"name":"sap_set_textedit","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Textedit"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set focus to any screen element by its ID.\n\nSome SAP actions require focus on a specific element before they work\n(e.g., F4 search help on a field). Use this to set focus before\nsending keys with sap_send_key.","inputSchema":{"additionalProperties":false,"properties":{"element_id":{"type":"string"}},"required":["element_id"],"type":"object"},"name":"sap_set_focus","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Focus"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read rows from a table on the current screen — ALV grid (report/list\noutput) or TableControl (SM30 maintenance view, customizing screens).\n\nAuto-detects the table type. The response includes a 'table_type' field\n('GuiGridView' for ALV or 'GuiTableControl') so you know which\ntype-specific tools to use next (e.g., sap_get_alv_toolbar for ALV,\nsap_scroll_table_control for TableControl).\n\nUse columns_only=true for schema discovery (returns column metadata\nonly, no data). For a TableControl it also gives each column's cell_type\nand a cell_id template ({row} = zero-based visible row) for\nsap_set_batch_fields. Use columns to fetch only specific columns (CSV).\nUse start_row to paginate through large tables. On a TableControl a\nstart_row (0 included) scrolls there first; without one the read starts\nwhere the table is scrolled now (e.g. after Position...).\nfirst_visible_row says which row is on top.\n\nA TableControl read returns at most the visible rows: page with\nstart_row=next_start_row while has_more is true. start_row_note\nexplains a clamped or failed scroll. total_rows counts its empty lines\ntoo (SM30 pads the view). When the read reaches the first empty row,\nthe response has empty_rows_from, that row's absolute index: the data\nends there.","inputSchema":{"additionalProperties":false,"properties":{"columns":{"default":"","type":"string"},"columns_only":{"default":false,"type":"boolean"},"max_rows":{"default":100,"type":"integer"},"start_row":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_read_table","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Table"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get all toolbar buttons from an ALV grid.\n\nReturns button IDs, texts, and types. Use this to discover available\nactions (sort, filter, export, etc.) before pressing them with\nsap_press_alv_toolbar_button. Only works on GuiGridView (ALV),\nnot GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_get_alv_toolbar","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Alv Toolbar"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Press a toolbar button on an ALV grid (e.g., sort, filter, export).\n\nUse sap_get_alv_toolbar to find button IDs. A menu button (Menu /\nButtonAndMenu) opens its menu and the response lists menu_items (text and\nfunction_code); pick one with sap_select_alv_context_menu_item.","inputSchema":{"additionalProperties":false,"properties":{"button_id":{"type":"string"},"grid_id":{"type":"string"}},"required":["grid_id","button_id"],"type":"object"},"name":"sap_press_alv_toolbar_button","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Alv Toolbar Button"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select an item from an opened ALV context menu.\n\nFirst use sap_press_alv_toolbar_button on a Menu button to open it,\nthen use this to select an item. Alternatively, pass toolbar_button_id\nto open the menu and select in one atomic call (recommended).\n\n`menu_item_id` can be a technical function code (for example `@M00006`),\nvisible menu text (for example `Confirm WT in Foreground`), or a position\ndescriptor. You can pass human-readable menu text directly. The\nmenu_items of sap_press_alv_toolbar_button list what a menu offers.\n\n`select_by` controls how selection is performed:\n- `auto` (default): heuristic based on whether `menu_item_id` has spaces\n- `id`: function code\n- `text`: visible menu text\n- `position`: position descriptor","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"},"menu_item_id":{"type":"string"},"select_by":{"default":"auto","enum":["auto","id","text","position"],"type":"string"},"toolbar_button_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null}},"required":["grid_id","menu_item_id"],"type":"object"},"name":"sap_select_alv_context_menu_item","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Alv Context Menu Item"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a row in a table/grid.\n\nWorks on both ALV grids and table controls. Row index is zero-based.\nFor ALV: uses absolute row index. For TableControl: scrolls to make\nthe row visible first if needed.","inputSchema":{"additionalProperties":false,"properties":{"row":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","row"],"type":"object"},"name":"sap_select_table_row","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Table Row"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a cell in a table/grid (often opens details or drills down).\n\nRow is zero-based. Column is the column name (from sap_read_table\nor sap_get_column_info). Works on both ALV and TableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"row":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","row","column"],"type":"object"},"name":"sap_double_click_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Modify the value of a cell in an ALV grid or table control.\n\nOnly works on editable cells. Use sap_get_cell_info to check if\na cell is changeable before attempting to modify it.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"},"value":{"type":"string"}},"required":["grid_id","row","column","value"],"type":"object"},"name":"sap_modify_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Modify Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Set the current (focused) cell in an ALV grid or table control.\n\nUseful before pressing toolbar buttons that act on the current cell.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"}},"required":["grid_id","row","column"],"type":"object"},"name":"sap_set_current_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Current Cell"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get detailed column info from an ALV grid or table control.\n\nReturns column names, titles and tooltips; for an ALV grid also each\ncolumn's data_type (string, date, decimal, ...) and key flag, for a table\ncontrol each column's cell_type and cell_id template. For a lighter\nalternative, use sap_read_table with columns_only=true.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_get_column_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Column Info"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get the currently focused cell position in an ALV grid or table control.","inputSchema":{"additionalProperties":false,"properties":{"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_get_current_cell","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Current Cell"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Scroll a GuiTableControl to a specific row position.\n\nDoes NOT work on ALV grids (they handle scrolling internally).\nFor reading data at a specific offset, prefer sap_read_table with\nstart_row parameter — it handles scrolling automatically.\n\nposition in the response is the row SAP actually put at the top, which\ncan differ from the one asked for (then requested_position and a note\nsay so). Cell IDs ([col,row]) count visible rows from that row.","inputSchema":{"additionalProperties":false,"properties":{"position":{"type":"integer"},"table_id":{"type":"string"}},"required":["table_id","position"],"type":"object"},"name":"sap_scroll_table_control","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Scroll Table Control"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get row metadata (selectable, selected) from a GuiTableControl.\n\nIf rows is omitted, queries all visible rows.\nDoes NOT work on ALV grids.","inputSchema":{"additionalProperties":false,"properties":{"rows":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"default":null},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_get_table_control_row_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Table Control Row Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select or deselect all columns in a GuiTableControl. Does NOT work on ALV grids.","inputSchema":{"additionalProperties":false,"properties":{"select":{"default":true,"type":"boolean"},"table_id":{"type":"string"}},"required":["table_id"],"type":"object"},"name":"sap_select_all_table_control_columns","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select All Table Control Columns"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Get detailed cell metadata from an ALV grid.\n\nReturns value, changeable, cell_type (Normal, CheckBox, ValueList,\nButton, ...), state (Normal, Error, Warning, Info: why a cell was\nrejected), f4_help, hotspot, color, tooltip, max_length; plus checked\nfor a checkbox and list_box_count (entries) for a dropdown cell.\nDoes NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"},"row":{"type":"integer"}},"required":["grid_id","row","column"],"type":"object"},"name":"sap_get_cell_info","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Cell Info"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Click a column header in an ALV grid (triggers sort). Does NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"column":{"type":"string"},"grid_id":{"type":"string"}},"required":["grid_id","column"],"type":"object"},"name":"sap_press_column_header","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Press Column Header"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select all rows in an ALV grid. Does NOT work on GuiTableControl.","inputSchema":{"additionalProperties":false,"properties":{"grid_id":{"type":"string"}},"required":["grid_id"],"type":"object"},"name":"sap_select_all_rows","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select All Rows"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select multiple rows at once in an ALV grid or table control.\n\nPass a list of row indices (e.g., [0, 2, 5]).","inputSchema":{"additionalProperties":false,"properties":{"rows":{"items":{"type":"integer"},"type":"array"},"table_id":{"type":"string"}},"required":["table_id","rows"],"type":"object"},"name":"sap_select_multiple_rows","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Multiple Rows"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Check if a popup/modal dialog is open (wnd[1], wnd[2], etc.).\n\nReturns the popup's title, text content, and available buttons so\nyou know how to respond. Also classifies the popup and suggests a\nsafe next action. Returns {popup_exists: false} if no popup.\n\nThe popup's text is in `texts`: labels and display-only fields (a\nmessage popup's lines). A popup whose body is a classic list (an F4\nhit list, a note, a message's long text) has `list` (`cells`, `rows`,\n`hint`) instead: its lines are never in `texts` or\n`interactive_elements`; read them with sap_read_list. Radio buttons\nand checkboxes in interactive_elements carry selected. `texts`,\n`buttons` and `interactive_elements` are left out when empty.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_get_popup_window","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Popup Window"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Read and optionally act on the current popup/modal dialog.\n\nUse when active_window shows wnd[1] or higher. Combines popup\ninspection and response in a single call.\n\nActions:\n- read: return popup content without acting (default)\n- confirm: press OK/Yes/Continue/Enter on the popup\n- cancel: press Cancel (or F12) on the popup; never No, which on a\n  save prompt drops the changes\n- press: press a specific button by its text or tooltip\n- auto: take only a clearly safe action; otherwise return the popup read-only\n\nA press that may save (a Save button, or Yes/OK on a popup about saving,\ne.g. \"Save the changes first?\") asks the user first, like F11 in\nsap_send_key. So does any answer but Cancel when the popup's question\ncannot be read (question_readable: false; SAP GUI's Edge browser\ncontrol). On such a popup, confirm never falls back to Enter, and auto\nonly reads. An accepted press reports confirmed_by_user: true.\n\nReturns the popup contents plus classification, requested action,\nand post-action screen/popup state when something was pressed.","inputSchema":{"additionalProperties":false,"properties":{"action":{"default":"read","enum":["read","confirm","cancel","press","auto"],"type":"string"},"button_text":{"default":"","type":"string"}},"type":"object"},"name":"sap_handle_popup","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Handle Popup"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"List all buttons on the system toolbar (tbar[0]) and app toolbar (tbar[1]).\n\nReturns button IDs, text, tooltip, and enabled state. This is for\nstandard SAP toolbars, NOT ALV (use sap_get_alv_toolbar for ALV).","inputSchema":{"additionalProperties":false,"properties":{"window_id":{"default":"wnd[0]","type":"string"}},"type":"object"},"name":"sap_get_toolbar_buttons","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Toolbar Buttons"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read content from a GuiShell subtype (e.g., HTMLViewer).\n\nAn HTML viewer's page text and URL are readable only with the Internet\nExplorer browser control; with the Edge control (SAP GUI 7.70+ default,\ne.g. the F1 Performance Assistant) the response says so in `note`.\nUse sap_get_screen_elements first to find shell element IDs.","inputSchema":{"additionalProperties":false,"properties":{"shell_id":{"type":"string"}},"required":["shell_id"],"type":"object"},"name":"sap_read_shell_content","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Shell Content"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read a classic ABAP list (WRITE output of a report) as lines of text.\n\nUse it when a report shows a plain list rather than an ALV grid (program\nSAPMSSY0, screen 120), and for F4 hit lists in a popup (window_id=\n'wnd[1]'). Such a list has no table object: every word is its own label,\nso sap_get_screen_elements leaves the cells out and reports it under\n'lists'. This returns the page as the lines the user sees, with no\nscreenshot needed.\n\n- colors: rows whose text has a semantic list colour, e.g. 'negative'\n  (red, errors), 'positive' (green), 'total', 'heading'\n- scroll: present when the list is longer than the page; pass\n  scroll_to=position+page_size to read the next page\n- with_ids=true adds the ID of each line's first label, to set the focus\n  on a line (sap_set_focus) before F2 / double-click\n- is_list=false means this screen has no list: use sap_read_table","inputSchema":{"additionalProperties":false,"properties":{"max_lines":{"default":200,"type":"integer"},"scroll_to":{"default":-1,"type":"integer"},"window_id":{"default":"wnd[0]","type":"string"},"with_ids":{"default":false,"type":"boolean"}},"type":"object"},"name":"sap_read_list","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read List"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Read data from a tree control (TableTreeControl, ColumnTreeControl, etc.).\n\nReturns node hierarchy with texts and column values. For large trees\n(e.g., SPRO with 1000+ nodes), use sap_get_tree_node_children for\nstep-by-step navigation instead. Use sap_search_tree_nodes to find\nspecific nodes by text.\n\ntotal_nodes is the number of nodes read; truncated=true means the tree\nhas more loaded nodes (available_nodes) than max_nodes allowed.","inputSchema":{"additionalProperties":false,"properties":{"max_nodes":{"default":200,"type":"integer"},"tree_id":{"type":"string"}},"required":["tree_id"],"type":"object"},"name":"sap_read_tree","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Read Tree"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Expand a folder node in a tree control to reveal its children.\n\nAfter expanding, use sap_get_tree_node_children or sap_read_tree\nto see the newly visible child nodes.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_expand_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Expand Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Collapse a folder node in a tree control (e.g. SPRO/customizing tree).","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_collapse_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Collapse Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Select a node in a tree control.\n\nHighlights the node without opening it. For SPRO-style trees,\nuse sap_click_tree_link on the execute icon column instead.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_select_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Select Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a node in a tree control (often opens details or drills down).\n\nIn SPRO/customizing trees, this may open documentation (hypertext)\nrather than executing the activity. Use sap_click_tree_link on the\nexecute column (typically column '2') for SPRO activities.","inputSchema":{"additionalProperties":false,"properties":{"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key"],"type":"object"},"name":"sap_double_click_tree_node","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Tree Node"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Double-click a specific item (column cell) in a tree node row.\n\nitem_name is the column name (e.g., 'Column1', 'Column2').\nUse sap_read_tree to discover column names for the tree.","inputSchema":{"additionalProperties":false,"properties":{"item_name":{"type":"string"},"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key","item_name"],"type":"object"},"name":"sap_double_click_tree_item","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Double Click Tree Item"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Click a hyperlink in a tree node item.\n\nFor SPRO/customizing trees, click on the execute icon column\n(typically item_name='2') to run an activity. Use sap_read_tree\nto see which columns have link-type items.","inputSchema":{"additionalProperties":false,"properties":{"item_name":{"type":"string"},"node_key":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","node_key","item_name"],"type":"object"},"name":"sap_click_tree_link","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Click Tree Link"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Find a tree node key by its path.\n\nE.g., '2\\1\\2' = 2nd child of root, then 1st child, then 2nd.","inputSchema":{"additionalProperties":false,"properties":{"path":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","path"],"type":"object"},"name":"sap_find_tree_node_by_path","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Find Tree Node By Path"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Search for tree nodes by text. Returns matches with full ancestor paths.\n\nUseful for finding nodes in deep trees where the same label appears\nin multiple branches. Case-insensitive substring match.\nOptionally pass column to search in a specific column instead of node text.\n\n**Important limitation**: Only searches nodes that are already loaded\n(expanded) in the tree. Collapsed subtrees are not searched. If you\ndon't find what you expect, expand parent nodes first using\nsap_get_tree_node_children with expand=true, then search again.\n\ntotal_matches counts the matches returned. stopped_early=true means the\nsearch reached max_results before the last loaded node, so more\nmatches are possible.","inputSchema":{"additionalProperties":false,"properties":{"column":{"default":"","type":"string"},"max_results":{"default":20,"type":"integer"},"search_text":{"type":"string"},"tree_id":{"type":"string"}},"required":["tree_id","search_text"],"type":"object"},"name":"sap_search_tree_nodes","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Search Tree Nodes"},{"_meta":{"fastmcp":{"tags":["write"]}},"annotations":{"destructiveHint":false,"readOnlyHint":false},"description":"Get direct children of a tree node. Much faster than read_tree for\nstep-by-step navigation of deep trees (e.g., SPRO).\n\nOmit node_key or pass empty string for root-level nodes.\nSet expand=true to expand the node first (requires write permission).","inputSchema":{"additionalProperties":false,"properties":{"expand":{"default":false,"type":"boolean"},"node_key":{"default":"","type":"string"},"tree_id":{"type":"string"}},"required":["tree_id"],"type":"object"},"name":"sap_get_tree_node_children","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Tree Node Children"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Discover all elements on the current SAP screen.\n\nUseful for finding field IDs when working with a new screen.\n\nUse type_filter and changeable_only to reduce response size on\ncomplex screens (e.g. type_filter=\"GuiTextField,GuiCTextField\"\nto find only input fields).\n\nmax_depth controls how deep to recurse into containers (default 2).\nUse max_depth=1 for a quick overview, max_depth=3+ for deeply nested\nlayouts (splitter containers, tab strips with sub-containers).\n\nPass container_id='wnd[0]/mbar' to discover the menu bar structure.\n\nRadio buttons and checkboxes report selected (true/false); a dropdown\nreports its selected key.\n\nA table control (SM30-style) is ONE element here, not one per cell: use\nsap_read_table(columns_only=true) for its columns and cell_id templates.\nA classic list (report WRITE output, SE16 standard list, F4 hit list) is\nleft out and reported under 'lists': read it with sap_read_list.\nexpand_tables=true lists every visible cell of both (large).\n\nDocking containers sit BESIDE the user area, not inside it: the\ndialog-structure tree of a view cluster (SM34, most IMG activities) and\nthe SE80 tree are under 'wnd[0]/shellcont'. When the window has any, the\nresponse lists them as docking_containers; discover them with that id,\nor pass container_id='wnd[0]' (max_depth=1) for all top-level areas.","inputSchema":{"additionalProperties":false,"properties":{"changeable_only":{"default":false,"type":"boolean"},"container_id":{"default":"wnd[0]/usr","type":"string"},"expand_tables":{"default":false,"type":"boolean"},"max_depth":{"default":2,"type":"integer"},"type_filter":{"default":"","type":"string"}},"type":"object"},"name":"sap_get_screen_elements","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Screen Elements"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Take a screenshot of the current SAP window.\n\nUse as a fallback when structured tools (sap_get_screen_elements,\nsap_read_field, sap_read_table) return empty or confusing results,\ne.g., on Web Dynpro screens where the element tree is non-standard.\n\nTo put a screenshot into a document, pass save_path (must end in .png,\ndirectory must exist, existing files are never overwritten). The file\nkeeps SAP GUI's full resolution; the inline image is capped at 1920px.\nThe response then also reports the absolute path and pixel size. Set\ninline=False to skip the image when only the file is needed.","inputSchema":{"additionalProperties":false,"properties":{"inline":{"default":true,"type":"boolean"},"save_path":{"default":"","type":"string"}},"type":"object"},"name":"sap_screenshot","title":"Sap Screenshot"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Render a preview card of the current SAP screen for the user:\nscreenshot, session/transaction info, status bar, and the values the\nagent is about to write (pending_fields). Call before significant\nwrites (batch fills, F11 save) or whenever the user asks to see\nwhat's about to happen. Read-only: nothing is written or saved.","inputSchema":{"additionalProperties":false,"properties":{"include_screenshot":{"default":true,"type":"boolean"},"note":{"default":"","type":"string"},"pending_fields":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"default":null}},"type":"object"},"name":"sap_preview","title":"Sap Preview"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Choose which SAP operations need the user's explicit approval first.\n\nReplaces this session's set of confirmation points. When a point is\nactive, every matching tool call pauses and asks the user to approve it\n(MCP elicitation) before anything reaches SAP; declining returns an error\nand nothing is executed.\n\nPoints:\n- transactions: sap_execute_transaction\n- batch_fields: sap_set_batch_fields\n- field_writes: sap_set_field, sap_modify_cell, sap_set_textedit,\n  sap_select_checkbox, sap_select_radio_button, sap_select_combobox_entry\n- all_writes: every write-tagged tool. Strict and noisy — many write tools\n  only select, scroll or navigate, and they will all prompt. Under\n  all_writes, sap_send_key(\"F11\") asks twice: once for the category and\n  once for the unchanged save gate.\n- attach: sap_connect_existing lets the user pick the SAP session in a\n  dialog, unless the call names a system with exactly one open session.\n\n'save' (F11 / Save key, Save toolbar button) is always on and cannot be\nturned off. Points set by the server's --confirm flag cannot be removed\neither. Adding a point is silent; *removing* one asks the user first, and\na declined removal keeps the point.\n\nConfirmation prompts block until the user answers, and on clients without\nelicitation support the gated call fails instead of running unconfirmed\n(same fail-closed rule as the save gate). On such a client points also\ncannot be removed, so activating one there blocks that whole category for\nthe rest of the session. Call sap_preview before a gated action so the\nuser can see the screen and pending values first.","inputSchema":{"additionalProperties":false,"properties":{"points":{"items":{"enum":["batch_fields","field_writes","transactions","all_writes","attach"],"type":"string"},"type":"array"}},"required":["points"],"type":"object"},"name":"sap_set_confirmation_points","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Set Confirmation Points"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Return step-by-step guidance for a common SAP workflow.\n\nAvailable workflows:\n- **search_help**: F4 search help on a field. `target` = field ID.\n- **table_export**: Paginated table export. `target` = table element ID.\n- **spro_navigate**: SPRO customizing navigation. `target` = activity name.","inputSchema":{"additionalProperties":false,"properties":{"target":{"type":"string"},"workflow":{"enum":["search_help","table_export","spro_navigate"],"type":"string"}},"required":["workflow","target"],"type":"object"},"name":"sap_get_workflow_guide","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Workflow Guide"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":false,"readOnlyHint":true},"description":"Return a generic, read-first guide for a supported SAP transaction.\n\nAvailable transactions:\n- **/SCWM/MON**: EWM Warehouse Monitor with tree navigation and ALV results.\n- **SM30**: table/view maintenance and view clusters (SM34) - also what\n  most IMG activities open: reading the table, the docked dialog-structure\n  tree, new entries, saving and the customizing request prompt.\n\nAliases accepted: `SCWM/MON`, `warehouse monitor`, `ewm warehouse monitor`,\n`SM34`, `table maintenance`, `view maintenance`, `view cluster`.","inputSchema":{"additionalProperties":false,"properties":{"task":{"default":"","type":"string"},"transaction":{"type":"string"}},"required":["transaction"],"type":"object"},"name":"sap_get_transaction_guide","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Get Transaction Guide"},{"_meta":{"fastmcp":{"tags":["read"]}},"annotations":{"destructiveHint":true,"readOnlyHint":false},"description":"Disconnect from the current SAP session and release the binding.\n\nCloses only the sessions this MCP session opened: the one sap_connect\nlogged on in and any /o window opened from it. Sessions that were\nattached (via sap_connect_existing), and /o windows opened from them, are\ndetached but left open so the user can continue working manually.","inputSchema":{"additionalProperties":false,"properties":{},"type":"object"},"name":"sap_disconnect","outputSchema":{"additionalProperties":true,"type":"object"},"title":"Sap Disconnect"}]}}}
