Skip to main content
Glama

ABAP Debug Stack

abap_debug_stack
Read-onlyIdempotent

Returns the call stack of a stopped ABAP debuggee as JSON so you can see where execution paused after a breakpoint hit before stepping or reading variables.

Instructions

Return the call stack of the stopped debuggee as JSON (the stack entries ADT reports). Use it after a breakpoint hit to see where you are before stepping or reading variables with abap_debug_variable. Read-only; needs an active session stopped at a breakpoint (abap_debug_session with action listen).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "abap_debug_stack"
  }
}

Input Schema

NameRequiredDescriptionDefault
connectionIdNoSAP system connection ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.16.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and idempotentHint, but the description adds genuinely new operational context: the session must already exist and be stopped at a breakpoint, and the result mirrors what ADT reports. It does not discuss stack depth limits or whether the snapshot can go stale, which would be the remaining behavioral detail.

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

Conciseness5/5

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

Three sentences, each doing distinct work: what is returned, when to call it relative to siblings, and the precondition. The precondition is front-loaded at the end of sentence one through 'stopped debuggee' and reinforced in sentence three; there is no filler.

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 single-parameter read tool with no output schema, the definition covers the return format (JSON ADT stack entries), the trigger, and the prerequisite session state. The only gap is what a stack entry contains, which an agent might want before parsing, but that is a minor omission given the stated ADT provenance.

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

Parameters3/5

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

Only one parameter (connectionId) and the schema already describes it at 100% coverage, so the schema carries the burden. The description adds no meaning about how connectionId relates to the debug session, but nothing is left 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 ('Return the call stack of the stopped debuggee') plus the output shape ('as JSON, the stack entries ADT reports'). The phrase 'stopped debuggee' and the pointer to stepping/variable siblings make it clearly distinct from abap_debug_step and abap_debug_variable.

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?

Explicitly says when to call it ('after a breakpoint hit ... before stepping or reading variables with abap_debug_variable') and names the prerequisite path ('needs an active session stopped at a breakpoint (abap_debug_session with action listen)'). Both the trigger condition and the alternative ordering are given.

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