Skip to main content
Glama
dnic-dev

bw-modeling-mcp

by dnic-dev

bw_add_process_chain_program

Add an ABAP program execution step to an existing Process Chain, positioning it before or after a specific step or appending it at the end. Supports optional selection variants and edge mode control.

Instructions

Add an "Execute ABAP Program" step (RSPC process type ABAP, "Programm ausführen") to an existing Process Chain (RSPC), via the BW/4HANA Cockpit REST API. Runs an ABAP report, optionally with a named SE38 selection variant. In-place edit: reads the current model, inserts the node + its INLINE process variant (the program call is stored inline in the chain — there is no separate variant object), and PUTs it back. Positioning: pass "before" to run the program ahead of an existing step (the target's incoming edges are rerouted through the new step, e.g. Start → PROGRAM → DTP); pass "after" to run it between a step and its successors; pass neither (optionally with predecessor) to append behind the strand end closest to the trigger. edge_mode "both" (default) adds an on-success and an on-error edge per new link; "success_only" adds only the on-success edge. Idempotent: if an ABAP step already calls the same program (and variant), it is skipped without writing. Only the synchronous/local/program call configuration is verified; keep the defaults. A 412 on the PUT means the ETag was stale (chain modified between read and write); the error reports this explicitly.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesProcess chain technical name (e.g. "CHAIN_NAME"). Case-insensitive.
afterNoInsert the program step AFTER this node — it runs between the target and its former successors. Mutually exclusive with "before".
localNoCall location. true (default) runs the program on this system (X_LOCAL). Only the default is verified.
beforeNoInsert the program step BEFORE this node (its DTP/variant name, or an aDSO held by an ADSOACT node). The target's incoming edges are rerouted through the new step. Mutually exclusive with "after".
programYesABAP program / report to execute (e.g. "REPORT_NAME").
variantNoOptional ABAP report (SE38) selection variant name (e.g. "VARIANT_NAME"). Omit to run the report without a variant.
activateNoIf true, activate the chain immediately after the edit. Default false.
edge_modeNo"both" (default): add an on-success and an on-error edge per new link. "success_only": add only the on-success edge.
descriptionNoOptional step description (cosmetic).
predecessorNoUsed only when neither before nor after is given. Node to append behind (a DTP/variant name, an aDSO held by an ADSOACT node) or the literal "strand_end_auto" (default = terminal node closest to the trigger).
synchronousNoCall mode. true (default) runs the program synchronously (X_SYNCHRON). Only the default is verified.
program_packageNoOptional package of the report (cosmetic value-help enrichment; the server re-derives it when omitted).
transport_requestNoOptional transport request to record the change into. Only relevant when the chain is in a transportable package (not $TMP). If the chain is transportable and exactly one request is available, it is chosen automatically; pass this to disambiguate when several are available. Ignored for $TMP (local) chains.
program_descriptionNoOptional report description (cosmetic).
variant_descriptionNoOptional variant description (cosmetic).
Behavior5/5

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

With no annotations, the description fully discloses behavior: in-place edit, idempotency (skip if same program/variant), edge rerouting details, and error handling. It also clarifies that only synchronous/local/defaults are verified. This provides comprehensive insight beyond the basic function.

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?

The description is detailed (~200 words) but efficiently combines multiple concepts: purpose, mechanism, positioning, edge mode, idempotency, and error handling. It is front-loaded with the core action. While concise given complexity, some technical details could be moved to notes, but overall it earns its space.

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

Completeness3/5

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

Given 15 parameters and no output schema, the description covers behavior, error handling, and positioning well. However, it does not describe the return value or output format for successful calls. For a tool without output schema, that omission leaves a gap, preventing the agent from fully understanding what to expect.

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

Parameters4/5

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

Schema coverage is 100% with descriptions for each parameter, so baseline is 3. The main description adds value by explaining how 'before', 'after', and 'predecessor' affect chain structure (e.g., rerouting), and gives examples ('Start → PROGRAM → DTP'). It goes beyond schema details to contextualize parameter usage.

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?

The description clearly states the tool adds an 'Execute ABAP Program' step to a Process Chain, specifying the API and mechanism. It uses specific verbs ('Add', 'runs an ABAP report') and distinguishes from sibling tools like bw_create_process_chain or bw_update_process_chain by focusing on inserting a program step into an existing chain.

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

Usage Guidelines4/5

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

The description explains positioning options (before, after, append), edge modes, and idempotency, providing clear guidance on how to insert the step. It also notes error handling (412 for stale ETag) but does not explicitly compare with alternatives for other step types or state when not to use this tool.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dnic-dev/bw-modeling-mcp'

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