Skip to main content
Glama

sap_save_variant

Save or update ABAP report selection-screen variants with values for parameters and select-options, enabling reuse in headless runs and avoiding manual entry of mandatory fields.

Instructions

Create or overwrite an ABAP selection-screen VARIANT for a report, so it can be reused by sap_run_program (and the performance trace / headless runs) for programs whose selection screen has mandatory fields. Parameter 'report' (required) is the program name. Parameter 'variant' (required) is the variant name (<=14 chars). Parameter 'text' (optional) is a description. Parameter 'environment' (optional, default 'A') is 'A' online or 'B' batch. Parameter 'parameters' (required) is the selection values as a list of objects with keys: selname, kind ('P' parameter / 'S' select-option), sign ('I'/'E'), option ('EQ','BT','CP',...), low, high. To read a variant back use sap_call_function RS_VARIANT_CONTENTS_RFC (REPORT, VARIANT); to delete use RS_VARIANT_DELETE_RFC (REPORT, VARIANT).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textNoVariant description (optional).
reportYesABAP report/program name. Will be uppercased.
variantYesVariant name, max 14 chars. Will be uppercased.
parametersYesSelection values (RSPARAMS rows).
environmentNoVariant environment: 'A' (online, default) or 'B' (batch).

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Addedv0.1.2

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral burden. It explicitly discloses the overwrite-capable side effect, the optional environment default, and related read/delete operations. It does not mention permissions or failure modes, but the core mutation behavior is clearly stated.

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 dense but well organized: purpose first, then parameter list, then related operations. It repeats some schema details, but every section earns its place and there is no fluff.

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?

Given the absence of annotations and output schema, the description covers the key aspects: creation/overwrite semantics, required vs optional parameters, parameter structure, default values, and how to read/delete variants afterward. It omits return-value details, but the tool is primarily a write operation.

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?

Schema coverage is 100% and the schema already documents every parameter and nested key. The description largely restates this information, adding only light context about being selection values and reuse. Since the schema does the heavy lifting, a baseline of 3 is appropriate.

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 states a specific action ('Create or overwrite an ABAP selection-screen VARIANT') on a concrete resource, and immediately ties it to reuse by sap_run_program. This clearly distinguishes it from the large set of sap_* siblings, most of which are read/query tools.

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?

It explains when this tool is relevant: for reports whose selection screen has mandatory fields and for use with sap_run_program, performance traces, or headless runs. It also gives alternatives for reading and deleting variants, though those are via sap_call_function rather than a listed sibling.

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

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/NicoHern/abapilot-mcp'

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