Skip to main content
Glama

ABAP Syntax Check

syntax_check
Read-onlyIdempotent

Runs an SAP syntax check on supplied ABAP source in the context of an existing object without saving or locking, returning line/column messages or a no-errors confirmation before you write source.

Instructions

Run the SAP syntax check on source text you supply, in the context of an existing object, without saving or locking anything. Returns each message as line:column, severity and text, or a no-errors confirmation. Use it before write_abap_object_source; use run_atc_analysis for quality checks on the saved object. Read-only; the object must already exist.

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": {
      "url": "<url>",
      "source": "<source>"
    },
    "name": "syntax_check"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesADT source URL of the object being checked (e.g. /sap/bc/adt/programs/programs/ZREPORT/source/main)
sourceYesThe complete ABAP source to check, as it would be saved (not a fragment)
mainUrlNoADT URL of the main object. Default and almost always right: the object itself (url without /source/main) — also for function modules, includes and classes.
connectionIdNoSAP system connection ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.16.2
    • changedInput schema / properties / source / description
      Previous value: -"ABAP source code to check"New value: +"The complete ABAP source to check, as it would be saved (not a fragment)"
    • changedInput schema / properties / url / description
      Previous value: -"ADT source URL of the object"New value: +"ADT source URL of the object being checked (e.g. /sap/bc/adt/programs/programs/ZREPORT/source/main)"
  2. First observedv1.16.0

TDQS

A4.3/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, and openWorldHint, so safety and idempotency are covered structurally. The description adds genuine value with the no-save/no-lock semantics and the return shape (line:column, severity, text, or a no-errors confirmation), which annotations cannot express. It stops short of deeper behavioral detail such as latency, message caps, or whether all messages or only errors are returned, so it sits at solid-adequate rather than rich.

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?

Four tight sentences: capability and its non-mutating guarantee first, then return format, then when to use, then the prerequisite. Every sentence carries information an agent needs, and there is no repetition of the title or schema.

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

Completeness5/5

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

Although there is no output schema, the description supplies the return shape itself, along with the prerequisite, the non-mutation guarantee, and routing to the ATC sibling. For a read-only validation tool with fully documented parameters, nothing material is missing.

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 description coverage is 100%, so all four parameters are already documented in the input schema, establishing a baseline of 3. The description reinforces that the source must be complete, not a fragment, and that an existing object context is required, but it adds nothing about mainUrl or connectionId beyond the schema text.

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 ("Run the SAP syntax check") plus the scope qualifier (source text you supply, in the context of an existing object) and explicitly contrasts with run_atc_analysis. An agent can distinguish this from the write, activate, and ATC siblings without opening any 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 sequencing ("Use it before write_abap_object_source"), names the alternative for a related need ("use run_atc_analysis for quality checks on the saved object"), and states the prerequisite that the object must already exist. Both when-to-use and when-to-use-something-else are covered.

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