Installation & Setup
This guide covers how to set up abapgit-agent to enable AI assistants (like Claude Code) to work with ABAP repositories.
Quick Start
# 1. Deploy agent to your SAP system (one-time setup)
# See "Step 1: Deploy Agent to ABAP System" below
# 2. Install CLI
npm install -g abapgit-agent
# 3. Initialize your ABAP project (run from git repo root)
abapgit-agent init --package ZMY_PACKAGE
# This copies CLAUDE.md, guidelines, and creates .abapGitAgent
# Defaults: --folder /src/ --folder-logic PREFIX
# 4. Edit .abapGitAgent with your SAP system details
# 5. Verify
abapgit-agent health
# 6. Pull from git to SAP
abapgit-agent pull
Prerequisites
ABAP System Requirements
- abapGit installed - Developer version required
- Follow the abapGit installation guide
- REST handler deployed - See Step 1 below
Local Requirements
- Node.js 16+
- Git
Step 1: Deploy Agent to ABAP System
This is a one-time setup for your SAP system.
1.1 Deploy ABAP Objects
Use abapGit to deploy all objects from the /abap folder.
1.2 Create SICF Service
- Run transaction
SICF - Navigate to:
sap/bc/z_abapgit_agent - If it doesn’t exist:
- Right-click on
sap/bc→ Create Element - Service Name:
Z_ABAPGIT_AGENT - Handler Class:
ZCL_ABGAGT_REST_HANDLER
- Right-click on
- Activate the service
Step 2: Install CLI
npm install -g abapgit-agent
# Verify installation
abapgit-agent health
Or for local development of abapgit-agent:
cd abapgit-agent
npm link
Step 3: Initialize Your ABAP Project
Run this from your ABAP git repository root:
abapgit-agent init --package ZMY_PACKAGE
Optional parameters:
--folder /src/(default:/src/)--folder-logic PREFIX(default:PREFIX, or useFULL)
This command:
- Creates
.abapGitAgentconfig file - Copies
CLAUDE.mdfor Claude Code integration - Copies
guidelines/folder for ABAP reference
After initialization, edit .abapGitAgent with your SAP system details. See init command docs for configuration options.
Verify: abapgit-agent health should return {"status": "OK", "version": "1.x.x"}.
Step 4: Import Existing Package (Optional)
If your ABAP package already has objects in SAP that you want to add to git:
- First, create the abapGit repository in ABAP:
- Option A:
abapgit-agent create - Option B: Create in abapGit UI
- Option A:
- Then import objects to git:
abapgit-agent import --message "Initial import from ZMY_PACKAGE"
This stages, commits, and pushes all objects from the package to your git repository.
See create and import command docs for more details.
Architecture
Claude (VS Code) → CLI Tool → ABAP System (REST/HTTP)
↓
Result + Error Feedback
- CLI Tool - Node.js REST client, reads config from
.abapGitAgent - ABAP Backend - REST handler with endpoints for pull, inspect, unit, tree, view, preview