Skip to main content
Glama
MCP SAP GUI Server

MCP SAP GUI Server

by kts982

Sap Read Tree

sap_read_tree
Read-only

Reads SAP GUI tree controls to return node hierarchies with texts and column values, enabling AI assistants to inspect tree data and navigate large trees via node children or search.

Instructions

Read data from a tree control (TableTreeControl, ColumnTreeControl, etc.).

Returns node hierarchy with texts and column values. For large trees (e.g., SPRO with 1000+ nodes), use sap_get_tree_node_children for step-by-step navigation instead. Use sap_search_tree_nodes to find specific nodes by text.

total_nodes is the number of nodes read; truncated=true means the tree has more loaded nodes (available_nodes) than max_nodes allowed. events lists what the application reacts to on this tree (e.g. link_click, item_double_click, node_double_click): other clicks do nothing there.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "tree_id": "<tree_id>"
    },
    "name": "sap_read_tree"
  }
}

Input Schema

NameRequiredDescriptionDefault
tree_idYes
max_nodesNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare it a safe read (readOnlyHint=true, destructiveHint=false), yet the description adds real behavioral context: how truncation works (truncated=true vs available_nodes against max_nodes) and which events the application actually reacts to, warning that other clicks do nothing. The only shortfall is that some of this overlaps what the existing output schema likely returns.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, then the alternative-tool guidance, then output semantics, each in its own short passage with no filler. Slightly dense, but every sentence carries information an agent needs.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter read tool with annotations and an output schema, the description supplies the missing usage routing, truncation semantics, and event behavior. It falls short only on identifying what tree_id refers to, which is the one thing an agent could still get wrong.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description carries the full burden, but it never explains tree_id — the required parameter — or how an agent obtains a valid one. max_nodes is only obliquely covered via the truncation explanation (and its default of 200 is only in the schema), so the critical parameter remains undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Read data from a tree control') and names the concrete control types it covers (TableTreeControl, ColumnTreeControl). It also distinguishes itself from sap_get_tree_node_children and sap_search_tree_nodes, so an agent can pick it without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit selection rules: use this for a bulk read, switch to sap_get_tree_node_children for large trees (SPRO with 1000+ nodes), and use sap_search_tree_nodes to locate nodes by text. Both the when-to-use and the alternatives are stated, not implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.