/abapsmith:abapsmith-write-abap-sourcefrom abapsmith
Writes ABAP source code for classes, interfaces, programs, function modules, and enhancement implementations. Includes dry-run previews and syntax error recovery guidance.
Ships in abapsmith. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
CLAS/OC INTF/OI PROG/P FUGR/F FUGR/FF ENHO/XHH — all source
shape. PROG/I and FUGR/I (includes) are also source shape and are
creatable and deletable.
Read the file for the object type you are about to write, in this directory:
| Writing | Read |
|---|---|
Class or interface (CLAS/OC, INTF/OI), ABAP Unit tests | classes.md |
Function group, function module, group include (FUGR/F, FUGR/FF, FUGR/I) | function-modules.md |
Report or include (PROG/P, PROG/I) | programs.md |
Enhancement implementation (ENHO/XHH) | enhancements.md |
Dry-run first when you want to see the diff before it lands: abap_write
resolves the target, reads the current source, applies edit/method/source
locally, and runs the safety gate — then returns a diff instead of writing.
abap_write { object, method, source, dry_run: true }
Read the diff. edit and method already supply the write's etag
automatically, so dropping dry_run and repeating the same call is enough
for those two forms. A plain {object, source} rewrite does not — pass the
preview's current_etag back explicitly as expect_etag:
abap_write { object, source, expect_etag }
That makes the applied write compare-before-write against exactly the bytes previewed, not whatever the object holds by the time the call lands.
To learn a method's signature, use method= with include="definitions";
do not read the full class:
abap_read { object: "CL_SALV_COLUMNS_TABLE", method: "GET_COLUMNS", include: "definitions" }
That returns the METHODS … declaration alone. method= without include
returns the declaration first, then the body. Both find members declared on
a superclass or interface and report foundOn; outline=true lists those
inherited members in their own section. A NOT_FOUND lists candidate names
from the whole chain — read it before guessing another name.
A full write whose syntax check fails is saved INACTIVE, not discarded. Fix
the reported lines (each message quotes the offending line with one line of
context) with abap_write { object, method, source } — method= resolves
against the inactive version, so no re-read is needed — then abap_activate.
Rewriting the whole class again also works; reading the active source back
does not, since it predates the failed write. If the response says the
just-created object was deleted again, nothing is saved — the source was
refused at save time (typically a missing period); write the whole object
again.
These are not caught by the syntax check in any object type:
SELECT … INTO TABLE with a select list in a different order than the target
structure gives shifted or empty fields, silently. Use INTO CORRESPONDING FIELDS OF TABLE.CO / CN / strlen on a fixed-length C(n) field count the trailing blanks; do character
tests on a STRING local after CONDENSE … NO-GAPS.CALL FUNCTION actuals are not checked against the module's types at activation; see
function-modules.md.Activation returns 200 even on failure — check chkl:messages for type: "E",
free in the response. The read-back is verified-mode only. Full checklist:
abapsmith-create-an-object.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub freight-art/abapsmith --plugin abapsmith18 skills in this plugin
/abapsmith-browse-img-customizingBrowses the SAP IMG (SPRO) customizing structure with abap_img — activities, their tree position, and the tables behind them. Use when asked what a customizing activity does, where a setting lives, or which table backs a view/transaction./abapsmith-check-code-qualityRuns ATC static checks with abap_atc and lists or applies ADT quick fixes with abap_quick_fix. Use when asked to review, clean up, or check an object for findings before it is transported./abapsmith-create-an-objectCreates, changes, or deletes an ABAP object with abap_write and checks whether it worked. Use for any mutation, and whenever a write returned success but the result looks wrong./abapsmith-create-a-rap-serviceBuilds a RAP stack — CDS view, behavior definition, service definition, service binding — in the correct order. Use when creating or extending an OData service from ABAP RAP artifacts./abapsmith-create-ddic-objectsCreates domains, data elements, table types, tables, structures, message classes, lock objects, and search helps in the right order with the right payload shape. Use for any DDIC dictionary object./abapsmith-debug-a-failing-runTurns a failed ABAP run into a diagnosis — the ST22 short dump with abap_dumps, then a live breakpoint with abap_debug. Use when a class or report short-dumped, raised an unexpected exception, or produced the wrong value.Other plugins' skills for the same job