Skip to main content
Glama

Scaffold a RAP business object

scaffold_rap_bo
Read-onlyIdempotent

Generate a full RAP managed BO stack: CDS views, behavior definitions, implementation class, projection views, UI metadata, and OData service. Use when starting a new RAP BO in ABAP Cloud.

Instructions

Generate the complete, canonical RAP managed business-object stack for one root entity: root CDS view entity, behavior definition (managed, strict(2), optional draft), behavior implementation class with handler locals, projection view with transactional_query, projection behavior definition, UI metadata extension, and an OData V4 service definition — plus a suggested table DDL, the activation order, and next steps. Use this when starting a new RAP business object in ABAP Cloud or S/4HANA and you want correct boilerplate that follows the SAP /DMO reference shape instead of writing it by hand. Generated classes and CDS views are round-trip validated through abaplint at ABAP-Cloud level before being returned; behavior and service definitions are canonical templates (abaplint does not parse those deeply) and ADT activation is the final check. It does not create the table or the service binding (binding is not a source artifact — create it in ADT), and it generates single-entity BOs: model compositions (parent-child) yourself for now. Example: scaffold_rap_bo({ "entityName": "Travel", "sqlTable": "ztravel", "keyField": "travel_id", "fields": [ { "name": "agency_id", "type": "abap.char(6)" } ], "draft": true }).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
draftNoGenerate draft handling (draft table reference, draft actions, use draft).
fieldsNoNon-key business fields. Admin fields (created_by/created_at/…) are added automatically.
prefixNoCustomer namespace prefix for all generated names.Z
keyFieldYessnake_case key field of that table, e.g. "travel_id".
sqlTableYesPersistent table the BO is backed by, e.g. "ztravel". Must start with the namespace prefix.
entityNameYesEntity name in UpperCamelCase, e.g. "Travel" — drives ZR_/ZC_/ZBP_/ZUI_ artifact names.
managedUuidKeyNotrue (default): UUID key filled by managed numbering — modern RAP default. false: the caller provides the key on create.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
filesYes
nextStepsYesWhat the generator cannot do for you (table, binding, draft table).
activationOrderYesThe order to create/activate artifacts in ADT.
validationIssuesYesabaplint findings on the generated sources — empty in normal operation.
suggestedTableDdlYesStarting-point DDL for the persistent table; adjust types.
Behavior4/5

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

Annotations already provide readOnlyHint=true and idempotentHint=true, and the description does not contradict them. The description adds useful behavioral context: round-trip validation via abaplint, that behavior/service definitions are canonical templates not deeply parsed, and ADT activation as the final check. This goes beyond the annotations to set expectations on quality and limitations.

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 long but densely informative—every sentence contributes: artifact list, usage, exclusions, validation, example. It is well-structured with a clear opening scope, conditional notes, and a concrete example. Not perfectly concise but appropriately detailed for a complex code-generation tool.

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?

The tool generates many artifacts and has an output schema; the description covers generated artifacts, potential caveats (validation depth, binding/table not created), next steps, and an example. With 7 parameters and an output schema, this description is enough for an agent to select and invoke correctly, and to interpret the result.

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 has 100% parameter description coverage, so baseline is 3. The description adds value through a concrete example that illustrates parameter usage and relationships (entityName, sqlTable, keyField, fields, draft), and clarifies defaults (e.g., prefix Z, admin fields auto-added). This supplements the schema without redundancy.

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?

Description uses a specific verb ('Generate') and details the exact resource ('the complete, canonical RAP managed business-object stack for one root entity') with an explicit list of artifacts. It clearly distinguishes from sibling tools (lint/format/check) and states its scope in the first sentence.

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?

Explicit usage guidance is provided: 'Use this when starting a new RAP business object in ABAP Cloud or S/4HANA' and contrasts with hand-writing. It also states exclusions ('does not create the table or the service binding', 'single-entity BOs: model compositions (parent-child) yourself'), giving clear when-to-use and when-not-to-use signals.

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/jackxiong11894/abap-lint-mcp'

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